
<!DOCTYPE HTML>
<!--generated with documentation_generator.py-->
<html>
<head>
    <link rel="stylesheet" href="api_reference.css">
    <title>ursina API Reference</title>
</head>
<body>
<input type="checkbox" id="checkbox" onClick="save()"></input>
<script>

function save() {
	var checkbox = document.getElementById("checkbox");
    localStorage.setItem("checkbox", checkbox.checked);
}

// loading
var checked = JSON.parse(localStorage.getItem("checkbox"));
document.getElementById("checkbox").checked = checked;

function copy_to_clipboard(containerid) {
    var range = document.createRange()
    range.selectNode(containerid)
    window.getSelection().removeAllRanges()
    window.getSelection().addRange(range)
    document.execCommand("copy")
    window.getSelection().removeAllRanges()
}

</script>
<bg></bg>
<div class="sidebar">
    <div class="sidebar_box" style="color: hsl(30deg 94% 21%);">
        <div class="group_header">Basics</div>
        <div class="group_content">
            <a href="#Ursina">Ursina</a><br>
            <a href="#Entity">Entity</a><br>
            <a href="#Button">Button</a><br>
            <a href="#Sprite">Sprite</a><br>
            <a href="#Text">Text</a><br>
            <a href="#Audio">Audio</a><br></div>
        <br>
    </div>
    
    <div class="sidebar_box" style="color: hsl(50deg 94% 21%);">
        <div class="group_header">Core Modules</div>
        <div class="group_content">
            <a href="#camera">camera</a><br>
            <a href="#mouse">mouse</a><br>
            <a href="#window">window</a><br>
            <a href="#application">application</a><br>
            <a href="#scene">scene</a><br></div>
        <br>
    </div>
    
    <div class="sidebar_box" style="color: hsl(70deg 94% 21%);">
        <div class="group_header">Graphics</div>
        <div class="group_content">
            <a href="#color">color</a><br>
            <a href="#Mesh">Mesh</a><br>
            <a href="#Shader">Shader</a><br>
            <a href="#Texture">Texture</a><br>
            <a href="#Light">Light</a><br>
            <a href="#DirectionalLight">DirectionalLight</a><br>
            <a href="#PointLight">PointLight</a><br>
            <a href="#AmbientLight">AmbientLight</a><br>
            <a href="#SpotLight">SpotLight</a><br></div>
        <br>
    </div>
    
    <div class="sidebar_box" style="color: hsl(90deg 94% 21%);">
        <div class="group_header">Procedural Models</div>
        <div class="group_content">
            <a href="#Quad">Quad</a><br>
            <a href="#Circle">Circle</a><br>
            <a href="#Plane">Plane</a><br>
            <a href="#Grid">Grid</a><br>
            <a href="#Cone">Cone</a><br>
            <a href="#Cylinder">Cylinder</a><br>
            <a href="#Pipe">Pipe</a><br>
            <a href="#Terrain">Terrain</a><br></div>
        <br>
    </div>
    
    <div class="sidebar_box" style="color: hsl(110deg 94% 21%);">
        <div class="group_header">modules</div>
        <div class="group_content">
            <a href="#input_handler">input_handler</a><br>
            <a href="#mesh_importer">mesh_importer</a><br>
            <a href="#texture_importer">texture_importer</a><br>
            <a href="#string_utilities">string_utilities</a><br></div>
        <br>
    </div>
    
    <div class="sidebar_box" style="color: hsl(130deg 94% 21%);">
        <div class="group_header">Animation</div>
        <div class="group_content">
            <a href="#Animation">Animation</a><br>
            <a href="#FrameAnimation3d">FrameAnimation3d</a><br>
            <a href="#SpriteSheetAnimation">SpriteSheetAnimation</a><br>
            <a href="#Animator">Animator</a><br>
            <a href="#TrailRenderer">TrailRenderer</a><br>
            <a href="#curve">curve</a><br></div>
        <br>
    </div>
    
    <div class="sidebar_box" style="color: hsl(150deg 94% 21%);">
        <div class="group_header">Math</div>
        <div class="group_content">
            <a href="#ursinamath">ursinamath</a><br>
            <a href="#Vec2">Vec2</a><br>
            <a href="#Vec3">Vec3</a><br>
            <a href="#Vec4">Vec4</a><br>
            <a href="#CubicBezier">CubicBezier</a><br></div>
        <br>
    </div>
    
    <div class="sidebar_box" style="color: hsl(170deg 94% 21%);">
        <div class="group_header">Gameplay</div>
        <div class="group_content">
            <a href="#ursinastuff">ursinastuff</a><br>
            <a href="#Sequence">Sequence</a><br>
            <a href="#Func">Func</a><br>
            <a href="#Keys">Keys</a><br></div>
        <br>
    </div>
    
    <div class="sidebar_box" style="color: hsl(190deg 94% 21%);">
        <div class="group_header">Collision</div>
        <div class="group_content">
            <a href="#raycast">raycast</a><br>
            <a href="#terraincast">terraincast</a><br>
            <a href="#boxcast">boxcast</a><br>
            <a href="#HitInfo">HitInfo</a><br>
            <a href="#Collider">Collider</a><br>
            <a href="#BoxCollider">BoxCollider</a><br>
            <a href="#SphereCollider">SphereCollider</a><br>
            <a href="#MeshCollider">MeshCollider</a><br></div>
        <br>
    </div>
    
    <div class="sidebar_box" style="color: hsl(210deg 94% 21%);">
        <div class="group_header">Prefabs</div>
        <div class="group_content">
            <a href="#Sky">Sky</a><br>
            <a href="#EditorCamera">EditorCamera</a><br>
            <a href="#Tilemap">Tilemap</a><br>
            <a href="#FirstPersonController">FirstPersonController</a><br>
            <a href="#PlatformerController2d">PlatformerController2d</a><br>
            <a href="#Conversation">Conversation</a><br>
            <a href="#Node">Node</a><br></div>
        <br>
    </div>
    
    <div class="sidebar_box" style="color: hsl(230deg 94% 21%);">
        <div class="group_header">UI</div>
        <div class="group_content">
            <a href="#Button">Button</a><br>
            <a href="#Draggable">Draggable</a><br>
            <a href="#Tooltip">Tooltip</a><br>
            <a href="#Slider">Slider</a><br>
            <a href="#ThinSlider">ThinSlider</a><br>
            <a href="#TextField">TextField</a><br>
            <a href="#Cursor">Cursor</a><br>
            <a href="#InputField">InputField</a><br>
            <a href="#ContentTypes">ContentTypes</a><br>
            <a href="#ButtonList">ButtonList</a><br>
            <a href="#ButtonGroup">ButtonGroup</a><br>
            <a href="#WindowPanel">WindowPanel</a><br>
            <a href="#Space">Space</a><br>
            <a href="#FileBrowser">FileBrowser</a><br>
            <a href="#FileButton">FileButton</a><br>
            <a href="#FileBrowserSave">FileBrowserSave</a><br>
            <a href="#DropdownMenu">DropdownMenu</a><br>
            <a href="#DropdownMenuButton">DropdownMenuButton</a><br>
            <a href="#RadialMenu">RadialMenu</a><br>
            <a href="#RadialMenuButton">RadialMenuButton</a><br>
            <a href="#HealthBar">HealthBar</a><br>
            <a href="#ColorPicker">ColorPicker</a><br></div>
        <br>
    </div>
    
    <div class="sidebar_box" style="color: hsl(250deg 94% 21%);">
        <div class="group_header">Editor</div>
        <div class="group_content">
            <a href="#HotReloader">HotReloader</a><br>
            <a href="#GridEditor">GridEditor</a><br>
            <a href="#PixelEditor">PixelEditor</a><br>
            <a href="#ASCIIEditor">ASCIIEditor</a><br></div>
        <br>
    </div>
    
    <div class="sidebar_box" style="color: hsl(270deg 94% 21%);">
        <div class="group_header">Scripts</div>
        <div class="group_content">
            <a href="#grid_layout">grid_layout</a><br>
            <a href="#duplicate">duplicate</a><br>
            <a href="#SmoothFollow">SmoothFollow</a><br>
            <a href="#Scrollable">Scrollable</a><br>
            <a href="#NoclipMode">NoclipMode</a><br>
            <a href="#NoclipMode2d">NoclipMode2d</a><br>
            <a href="#build">build</a><br></div>
        <br>
    </div>
    
    <div class="sidebar_box" style="color: hsl(290deg 94% 21%);">
        <div class="group_header">Assets</div>
        <div class="group_content">
            <a href="#models">models</a><br>
            <a href="#textures">textures</a><br></div>
        <br>
    </div>
    
    <div class="sidebar_box" style="color: hsl(310deg 94% 21%);">
        <div class="group_header">Shaders</div>
        <div class="group_content">
            <a href="#unlit_shader">unlit_shader</a><br>
            <a href="#lit_with_shadows_shader">lit_with_shadows_shader</a><br>
            <a href="#matcap_shader">matcap_shader</a><br>
            <a href="#colored_lights_shader">colored_lights_shader</a><br>
            <a href="#fresnel_shader">fresnel_shader</a><br>
            <a href="#projector_shader">projector_shader</a><br>
            <a href="#texture_blend_shader">texture_blend_shader</a><br>
            <a href="#instancing_shader">instancing_shader</a><br>
            <a href="#triplanar_shader">triplanar_shader</a><br>
            <a href="#normals_shader">normals_shader</a><br>
            <a href="#transition_shader">transition_shader</a><br>
            <a href="#fxaa">fxaa</a><br>
            <a href="#ssao">ssao</a><br>
            <a href="#camera_outline_shader">camera_outline_shader</a><br>
            <a href="#pixelation_shader">pixelation_shader</a><br>
            <a href="#camera_contrast">camera_contrast</a><br>
            <a href="#camera_vertical_blur">camera_vertical_blur</a><br>
            <a href="#camera_grayscale">camera_grayscale</a><br></div>
        <br>
    </div>
    </div>
<main_section>
    <h1 class="main_header">ursina API Reference</h1>
    <p>v7.0.0</p>
    <div class="class_box" id="Ursina">
        <h1>Ursina</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/main.py"><gray>ursina/main</gray></a><br><br>
        <div class="params">Ursina(title='ursina', icon='textures/ursina.ico', borderless=False, fullscreen=False, size=None, forced_aspect_ratio=None, position=None, vsync=True, editor_ui_enabled=True, window_type='onscreen', development_mode=True, render_mode=None, show_ursina_splash=False, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.mouse<gray> = mouse</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;input_up(<gray>key, is_raw=False</gray>)</td> <td><span>internal method for key release</span></td>
            </tr>
            <tr>
                <td> &nbsp;input_hold(<gray>key, is_raw=False</gray>)</td> <td><span>internal method for handling repeating input that occurs when you hold the key</span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key, is_raw=False</gray>)</td> <td><span>internal method for handling input</span></td>
            </tr>
            <tr>
                <td> &nbsp;text_input(<gray>key</gray>)</td> <td><span>internal method for handling text input</span></td>
            </tr>
            <tr>
                <td> &nbsp;step(<gray>): # use this control the update loop yourself. call app.step() in a while loop for example, instead of app.run(</gray>)</td> <td><span>use this control the update loop yourself. call app.step() in a while loop for example, instead of app.run()</span></td>
            </tr>
            <tr>
                <td> &nbsp;run(<gray>info=True</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Ursina_example)">copy</button><p id="Ursina_example"><purple>from</purple> ursina <purple>import</purple> *
app = <purple><b>Ursina</b></purple>(development_<olive>mode</olive>=False, use_ingame_console=True)
<purple>def</purple> input(key):
    <blue>print</blue>(key)
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Entity">
        <h1>Entity<a style="color: gray; font-weight:normal;" href="#, metaclass=PostInitCaller">(, metaclass=PostInitCaller)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/entity.py"><gray>ursina/entity</gray></a><br><br>
        <div class="params">Entity(add_to_scene_entities=True, enabled=True, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>Entity.rotation_directions = (-1,-1,1)</td><td></td>
            </tr>
            <tr>
                <td>.name<gray> = camel_to_snake(self.__class__.__name__)</gray></td><td></td>
            </tr>
            <tr>
                <td>.ignore<gray> = False     </gray></td><td><span>if True, will not try to run code.</span></td>
            </tr>
            <tr>
                <td>.ignore_paused<gray> = False      </gray></td><td><span>if True, will still run when application is paused. useful when making a pause menu for example.</span></td>
            </tr>
            <tr>
                <td>.ignore_input<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.parent<gray> = scene     </gray></td><td><span>default parent is scene, which means it's in 3d space. to use UI space, set the parent to camera.ui instead.</span></td>
            </tr>
            <tr>
                <td>.add_to_scene_entities<gray> = add_to_scene_entities </gray></td><td><span>set to False to be ignored by the engine, but still get rendered.</span></td>
            </tr>
            <tr>
                <td>.scripts<gray> = []   </gray></td><td><span>add with add_script(class_instance). will assign an 'entity' variable to the script.</span></td>
            </tr>
            <tr>
                <td>.animations<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.hovered<gray> = False    </gray></td><td><span>will return True if mouse hovers entity.</span></td>
            </tr>
            <tr>
                <td>.line_definition<gray> = None </gray></td><td><span>returns a Traceback(filename, lineno, function, code_context, index).</span></td>
            </tr>
            <tr>
                <td>.enabled<gray> = enabled</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.enabled</td><td><span>disabled entities will not be visible nor run code.</span></td>
            </tr>
            <tr>
                <td>.model</td><td><span>set model with model='model_name' (without file type extension)</span></td>
            </tr>
            <tr>
                <td>.color</td><td><span></span></td>
            </tr>
            <tr>
                <td>.eternal</td><td><span>eternal entities does not get destroyed on scene.clear()</span></td>
            </tr>
            <tr>
                <td>.double_sided</td><td><span></span></td>
            </tr>
            <tr>
                <td>.render_queue</td><td><span>for custom sorting in case of conflict. To sort things in 2d, set .z instead of using this.</span></td>
            </tr>
            <tr>
                <td>.parent</td><td><span></span></td>
            </tr>
            <tr>
                <td>.loose_parent</td><td><span></span></td>
            </tr>
            <tr>
                <td>.world_parent</td><td><span>change the parent, but keep position, rotation and scale</span></td>
            </tr>
            <tr>
                <td>.types</td><td><span>get all class names including those this inhertits from.</span></td>
            </tr>
            <tr>
                <td>.visible</td><td><span></span></td>
            </tr>
            <tr>
                <td>.visible_self</td><td><span>set visibility of self, without affecting children.</span></td>
            </tr>
            <tr>
                <td>.collider</td><td><span>set to 'box'/'sphere'/'capsule'/'mesh' for auto fitted collider.</span></td>
            </tr>
            <tr>
                <td>.collision</td><td><span>toggle collision without changing collider.</span></td>
            </tr>
            <tr>
                <td>.on_click</td><td><span></span></td>
            </tr>
            <tr>
                <td>.origin</td><td><span></span></td>
            </tr>
            <tr>
                <td>.origin_x</td><td><span></span></td>
            </tr>
            <tr>
                <td>.origin_y</td><td><span></span></td>
            </tr>
            <tr>
                <td>.origin_z</td><td><span></span></td>
            </tr>
            <tr>
                <td>.world_position</td><td><span></span></td>
            </tr>
            <tr>
                <td>.world_x</td><td><span></span></td>
            </tr>
            <tr>
                <td>.world_y</td><td><span></span></td>
            </tr>
            <tr>
                <td>.world_z</td><td><span></span></td>
            </tr>
            <tr>
                <td>.position</td><td><span>right, up, forward. can also set self.x, self.y, self.z</span></td>
            </tr>
            <tr>
                <td>.x</td><td><span></span></td>
            </tr>
            <tr>
                <td>.y</td><td><span></span></td>
            </tr>
            <tr>
                <td>.z</td><td><span></span></td>
            </tr>
            <tr>
                <td>.X</td><td><span>shortcut for int(entity.x)</span></td>
            </tr>
            <tr>
                <td>.Y</td><td><span>shortcut for int(entity.y)</span></td>
            </tr>
            <tr>
                <td>.Z</td><td><span>shortcut for int(entity.z)</span></td>
            </tr>
            <tr>
                <td>.world_rotation</td><td><span></span></td>
            </tr>
            <tr>
                <td>.world_rotation_x</td><td><span></span></td>
            </tr>
            <tr>
                <td>.world_rotation_y</td><td><span></span></td>
            </tr>
            <tr>
                <td>.world_rotation_z</td><td><span></span></td>
            </tr>
            <tr>
                <td>.rotation</td><td><span>can also set self.rotation_x, self.rotation_y, self.rotation_z</span></td>
            </tr>
            <tr>
                <td>.rotation_x</td><td><span></span></td>
            </tr>
            <tr>
                <td>.rotation_y</td><td><span></span></td>
            </tr>
            <tr>
                <td>.rotation_z</td><td><span></span></td>
            </tr>
            <tr>
                <td>.quaternion</td><td><span></span></td>
            </tr>
            <tr>
                <td>.world_scale</td><td><span></span></td>
            </tr>
            <tr>
                <td>.world_scale_x</td><td><span></span></td>
            </tr>
            <tr>
                <td>.world_scale_y</td><td><span></span></td>
            </tr>
            <tr>
                <td>.world_scale_z</td><td><span></span></td>
            </tr>
            <tr>
                <td>.scale</td><td><span>can also set self.scale_x, self.scale_y, self.scale_z</span></td>
            </tr>
            <tr>
                <td>.scale_x</td><td><span></span></td>
            </tr>
            <tr>
                <td>.scale_y</td><td><span></span></td>
            </tr>
            <tr>
                <td>.scale_z</td><td><span></span></td>
            </tr>
            <tr>
                <td>.transform</td><td><span>get/set position, rotation and scale</span></td>
            </tr>
            <tr>
                <td>.world_transform</td><td><span>get/set world_position, world_rotation and world_scale</span></td>
            </tr>
            <tr>
                <td>.forward</td><td><span>get forward direction.</span></td>
            </tr>
            <tr>
                <td>.back</td><td><span>get backwards direction.</span></td>
            </tr>
            <tr>
                <td>.right</td><td><span>get right direction.</span></td>
            </tr>
            <tr>
                <td>.left</td><td><span>get left direction.</span></td>
            </tr>
            <tr>
                <td>.up</td><td><span>get up direction.</span></td>
            </tr>
            <tr>
                <td>.down</td><td><span>get down direction.</span></td>
            </tr>
            <tr>
                <td>.screen_position</td><td><span>get screen position(ui space) from world space.</span></td>
            </tr>
            <tr>
                <td>.shader</td><td><span></span></td>
            </tr>
            <tr>
                <td>.shader_input</td><td><span></span></td>
            </tr>
            <tr>
                <td>.material</td><td><span>a way to set shader, texture, texture_scale, texture_offset and shader inputs in one go</span></td>
            </tr>
            <tr>
                <td>.texture</td><td><span>set model with texture='texture_name'. requires a model to be set beforehand.</span></td>
            </tr>
            <tr>
                <td>.texture_scale</td><td><span>how many times the texture should repeat, eg. texture_scale=(8,8).</span></td>
            </tr>
            <tr>
                <td>.texture_offset</td><td><span></span></td>
            </tr>
            <tr>
                <td>.tileset_size</td><td><span>if the texture is a tileset, say how many tiles there are so it only use one tile of the texture, e.g. tileset_size=[8,4]</span></td>
            </tr>
            <tr>
                <td>.tile_coordinate</td><td><span>set the tile coordinate, starts in the lower left.</span></td>
            </tr>
            <tr>
                <td>.alpha</td><td><span>shortcut for setting color's transparency/opacity</span></td>
            </tr>
            <tr>
                <td>.always_on_top</td><td><span></span></td>
            </tr>
            <tr>
                <td>.unlit</td><td><span>set to True to ignore light and not cast shadows</span></td>
            </tr>
            <tr>
                <td>.billboard</td><td><span>set to True to make this Entity always face the camera.</span></td>
            </tr>
            <tr>
                <td>.wireframe</td><td><span>set to True to render model as wireframe</span></td>
            </tr>
            <tr>
                <td>.model_bounds</td><td><span></span></td>
            </tr>
            <tr>
                <td>.bounds</td><td><span></span></td>
            </tr>
            <tr>
                <td>.flipped_faces</td><td><span></span></td>
            </tr>
            <tr>
                <td>.children</td><td><span></span></td>
            </tr>
            <tr>
                <td>.loose_children</td><td><span></span></td>
            </tr>
            <tr>
                <td>.attributes</td><td><span>attribute names. used by duplicate().</span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;enable()</td> <td><span>same as .enabled = True</span></td>
            </tr>
            <tr>
                <td> &nbsp;disable()</td> <td><span>same as .enabled = False</span></td>
            </tr>
            <tr>
                <td> &nbsp;get_shader_input(<gray>name</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;set_shader_input(<gray>name, value</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;generate_sphere_map(<gray>size=512, name=f'sphere_map_{len(scene.entities)}'</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;generate_cube_map(<gray>size=512, name=f'cube_map_{len(scene.entities)}'</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;get_position(<gray>relative_to=scene</gray>)</td> <td><span>get position relative to on other Entity. In most cases, use .position instead.</span></td>
            </tr>
            <tr>
                <td> &nbsp;set_position(<gray>value, relative_to=scene</gray>)</td> <td><span>set position relative to on other Entity. In most cases, use .position instead.</span></td>
            </tr>
            <tr>
                <td> &nbsp;rotate(<gray>value, relative_to=None</gray>)</td> <td><span>rotate around local axis.</span></td>
            </tr>
            <tr>
                <td> &nbsp;add_script(<gray>class_instance</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;combine(<gray>analyze=False, auto_destroy=True, ignore=[], ignore_disabled=True, include_normals=False</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;look_at(<gray>target, axis='forward', up=None</gray>)</td> <td><span>up defaults to self.up</span></td>
            </tr>
            <tr>
                <td> &nbsp;look_at_2d(<gray>target, axis='z'</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;look_at_xy(<gray>target</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;look_at_xz(<gray>target</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;has_ancestor(<gray>possible_ancestor</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;has_disabled_ancestor()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;get_changes(<gray>target_class=None</gray>)</td> <td><span>returns a dict of all the changes</span></td>
            </tr>
            <tr>
                <td> &nbsp;animate(<gray>name, value, duration=.1, delay=0, curve=curve.in_expo, loop=False, resolution=None, interrupt='kill', time_step=None, unscaled=False, auto_play=True, auto_destroy=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;animate_position(<gray>value, duration=.1, **kwargs</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;animate_rotation(<gray>value, duration=.1,  **kwargs</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;animate_scale(<gray>value, duration=.1, **kwargs</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;animate_{e}(<gray>value, duration=.1, delay=0, unscaled=False, **kwargs</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;shake(<gray>duration=.2, magnitude=1, speed=.05, direction=(1,1), delay=0, attr_name='position', interrupt='finish', unscaled=False</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;animate_color(<gray>value, duration=.1, interrupt='finish', unscaled=False, **kwargs</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;fade_out(<gray>value=0, duration=.5, unscaled=False, **kwargs</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;fade_in(<gray>value=1, duration=.5, **kwargs</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;blink(<gray>value=ursina.color.clear, duration=.1, delay=0, curve=curve.in_expo_boomerang, interrupt='finish', **kwargs</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;intersects(<gray>traverse_target=scene, ignore:list=None, debug=False</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Entity_example)">copy</button><p id="Entity_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()

e = <olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>, <olive>color</olive>=color.orange, <olive>position</olive>=(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>1</yellow>), <olive>scale</olive>=<yellow>1</yellow>.<yellow>5</yellow>, <olive>rotation</olive>=(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>4</yellow><yellow>5</yellow>), <olive>texture</olive>=<green>'brick'</green>)

<green><green><green>''</green></green>'example of inheriting Entity<green><green>''</green></green>'</green>
class Player(<olive>Entity</olive>):
    <purple>def</purple> __init__(self, **kwargs):
        super().__init__()
        self.<olive>model</olive>=<green>'cube'</green>
        self.color = color.red
        self.scale_y = <yellow>2</yellow>

        <purple>for</purple> key, value in kwargs.items():
            <blue>setattr</blue>(self, key, value)

    <purple>def</purple> input(self, key):
        <purple>if</purple> key == <green>'space'</green>:
            self.animate_x(<yellow>2</yellow>, duration=<yellow>1</yellow>)

    <purple>def</purple> update(self):
        self.x += held_keys[<green>'d'</green>] * time.dt * <yellow>1</yellow><yellow>0</yellow>
        self.x -= held_keys[<green>'a'</green>] * time.dt * <yellow>1</yellow><yellow>0</yellow>

player = Player(x=-<yellow>1</yellow>)</p>
</div>

</div>
<br>
    <div class="class_box" id="Button">
        <h1>Button<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/button.py"><gray>ursina/prefabs/button</gray></a><br><br>
        <div class="params">Button(text='', parent=camera.ui, model=Default, radius=.1, origin=(0,0), text_origin=(0,0), text_size=1, color=Default, collider='box', highlight_scale=1, pressed_scale=1, disabled=False, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.origin<gray> = origin</gray></td><td></td>
            </tr>
            <tr>
                <td>.color<gray> = color</gray></td><td></td>
            </tr>
            <tr>
                <td>.highlight_color<gray> = self.color.tint(.2)</gray></td><td></td>
            </tr>
            <tr>
                <td>.pressed_color<gray> = self.color.tint(-.2)</gray></td><td></td>
            </tr>
            <tr>
                <td>.highlight_scale<gray> = highlight_scale    </gray></td><td><span>multiplier</span></td>
            </tr>
            <tr>
                <td>.pressed_scale<gray> = pressed_scale     </gray></td><td><span>multiplier</span></td>
            </tr>
            <tr>
                <td>.highlight_sound<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.pressed_sound<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.collider<gray> = collider</gray></td><td></td>
            </tr>
            <tr>
                <td>.disabled<gray> = disabled</gray></td><td></td>
            </tr>
            <tr>
                <td>.text_entity<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.text_origin<gray> = text_origin</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.text</td><td><span></span></td>
            </tr>
            <tr>
                <td>.text_origin</td><td><span></span></td>
            </tr>
            <tr>
                <td>.text_color</td><td><span></span></td>
            </tr>
            <tr>
                <td>.icon</td><td><span></span></td>
            </tr>
            <tr>
                <td>.icon_world_scale</td><td><span></span></td>
            </tr>
            <tr>
                <td>.text_size</td><td><span></span></td>
            </tr>
            <tr>
                <td>.origin</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_mouse_enter()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_mouse_exit()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;fit_to_text(<gray>radius=.1, padding=Vec2(Text.size*1.5, Text.size)</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Button_example)">copy</button><p id="Button_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()

Button.default_color = color.red
b = <purple><b>Button</b></purple>(<olive>model</olive>=<green>'quad'</green>, <olive>scale</olive>=.<yellow>0</yellow><yellow>5</yellow>, x=-.<yellow>5</yellow>, <olive>color</olive>=color.lime, <olive>text</olive>=<green>'text scale\ntest'</green>, text_size=.<yellow>5</yellow>, text_<olive>color</olive>=color.black)
b.text_size = .<yellow>5</yellow>
b.on_click = Sequence(Wait(.<yellow>5</yellow>), Func(print, <green>'aaaaaa'</green>), )

b = <purple><b>Button</b></purple>(<olive>parent</olive>=camera.ui, <olive>text</olive>=<green>'hello world!'</green>, <olive>scale</olive>=.<yellow>2</yellow><yellow>5</yellow>)
Button.default_color = color.blue
b = <purple><b>Button</b></purple>(<olive>text</olive>=<green>'hello world!'</green>, <olive>icon</olive>=<green>'sword'</green>, <olive>scale</olive>=.<yellow>2</yellow><yellow>5</yellow>, text_<olive>origin</olive>=(-.<yellow>5</yellow>,<yellow>0</yellow>), x=.<yellow>5</yellow>)
b.on_click = application.quit <gray># assign a function to the button.</gray>
b.tooltip = Tooltip(<green>'exit'</green>)

par = <olive>Entity</olive>(<olive>parent</olive>=camera.ui, <olive>scale</olive>=.<yellow>2</yellow>, <olive>y</olive>=-.<yellow>2</yellow>)
b = <purple><b>Button</b></purple>(<olive>parent</olive>=par, <olive>text</olive>=<green>'test'</green>, <olive>scale_x</olive>=<yellow>1</yellow>, <olive>origin</olive>=(-.<yellow>5</yellow>,.<yellow>5</yellow>))
b.text =<green>'new text'</green>
<blue>print</blue>(b.text_entity)

<purple><b>Button</b></purple>(<olive>text</olive>=<green>'sound'</green>, <olive>scale</olive>=.<yellow>2</yellow>, <olive>position</olive>=(-.<yellow>2</yellow><yellow>5</yellow>,-.<yellow>2</yellow>), <olive>color</olive>=color.pink, highlight_sound=<green>'blip_1'</green>, pressed_sound=Audio(<green>'coin_1'</green>, autopla<olive>y</olive>=False))

Text(<green>'Text size\nreference'</green>, x=.<yellow>1</yellow><yellow>5</yellow>)
<purple>def</purple> input(key):

    <purple>if</purple> key == <green>'d'</green>:
        scene.clear()

    <purple>if</purple> key == <green>'space'</green>:
        b.text = <green>'updated text'</green>


app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Sprite">
        <h1>Sprite<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/sprite.py"><gray>ursina/prefabs/sprite</gray></a><br><br>
        <div class="params">Sprite(texture=None, ppu:int=None, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>Sprite.ppu = 100</td><td></td>
            </tr>
            <tr>
                <td>.model<gray> = 'quad'</gray></td><td></td>
            </tr>
            <tr>
                <td>.texture<gray> = texture</gray></td><td></td>
            </tr>
            <tr>
                <td>.ppu<gray> = ppu if ppu else Sprite.ppu   </gray></td><td><span>pixels per unit</span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;update_scale()</td> <td><span>get called automatically on __init__, but if you change the texture or ppu, you can call this to update the scale.</span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Sprite_example)">copy</button><p id="Sprite_example">app = Ursina()
camera.orthographic = True
camera.fov = <yellow>1</yellow>
Sprite.ppu = <yellow>1</yellow><yellow>6</yellow>
Texture.default_filtering = None
s = <purple><b>Sprite</b></purple>(<green>'brick'</green>, filtering=False)
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Text">
        <h1>Text<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/text.py"><gray>ursina/text</gray></a><br><br>
        <div class="params">Text(text='', start_tag=start_tag, end_tag=end_tag, ignore=True, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>Text.size = .025</td><td></td>
            </tr>
            <tr>
                <td>.size<gray> = Text.size</gray></td><td></td>
            </tr>
            <tr>
                <td>.parent<gray> = camera.ui</gray></td><td></td>
            </tr>
            <tr>
                <td>.shader<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.text_nodes<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.images<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.origin<gray> = (-.5, .5)</gray></td><td></td>
            </tr>
            <tr>
                <td>.font<gray> = Text.default_font</gray></td><td></td>
            </tr>
            <tr>
                <td>.resolution<gray> = Text.default_resolution</gray></td><td></td>
            </tr>
            <tr>
                <td>.use_tags<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.line_height<gray> = 1</gray></td><td></td>
            </tr>
            <tr>
                <td>.start_tag<gray> = start_tag</gray></td><td></td>
            </tr>
            <tr>
                <td>.end_tag<gray> = end_tag</gray></td><td></td>
            </tr>
            <tr>
                <td>.text_colors<gray> = {'default' : color.text_color}</gray></td><td></td>
            </tr>
            <tr>
                <td>.tag<gray> = Text.start_tag+'default'+Text.end_tag</gray></td><td></td>
            </tr>
            <tr>
                <td>.current_color<gray> = self.text_colors['default']</gray></td><td></td>
            </tr>
            <tr>
                <td>.scale_override<gray> = 1</gray></td><td></td>
            </tr>
            <tr>
                <td>.appear_sequence<gray> = None </gray></td><td><span>gets created when calling appear()</span></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.text</td><td><span></span></td>
            </tr>
            <tr>
                <td>.font</td><td><span></span></td>
            </tr>
            <tr>
                <td>.color</td><td><span>sets the default color.</span></td>
            </tr>
            <tr>
                <td>.line_height</td><td><span></span></td>
            </tr>
            <tr>
                <td>.width</td><td><span>gets the width of the widest line.</span></td>
            </tr>
            <tr>
                <td>.height</td><td><span>gets the height of the text</span></td>
            </tr>
            <tr>
                <td>.lines</td><td><span></span></td>
            </tr>
            <tr>
                <td>.resolution</td><td><span></span></td>
            </tr>
            <tr>
                <td>.wordwrap</td><td><span>set this to make the text wrap after a certain number of characters.</span></td>
            </tr>
            <tr>
                <td>.origin</td><td><span></span></td>
            </tr>
            <tr>
                <td>.background</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;text(<gray>text</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;create_text_section(<gray>text, tag='', x=0, y=0</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;align()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;create_background(<gray>padding=size*2, radius=size, color=ursina.color.black66</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;appear(<gray>speed=.025</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;get_width(<gray>string, font=None</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Text_example)">copy</button><p id="Text_example"><purple>from</purple> ursina <purple>import</purple> *
  <purple>from</purple> ursina <purple>import</purple> Ursina, dedent, window
  app = Ursina()
  descr = dedent(<green><green>''</green>'
      &ltred&gtRainstorm&ltdefault&gt &ltred&gtRainstorm&ltdefault&gt
      Summon a rain storm to deal 5 &ltblue&gtwater&ltdefault&gt damage to everyone, test including yourself.
      1234 1234 1234 1234 1234 1234 2134 1234 1234 1234 1234 1234 2134 2134 1234 1234 1234 1234
      Lasts for 4 rounds.<green>''</green>'</green>).strip()

  Text.default_resolution = <yellow>1</yellow><yellow>0</yellow><yellow>8</yellow><yellow>0</yellow> * Text.size
  test = <purple><b>Text</b></purple>(<olive>text</olive>=descr, wordwrap=<yellow>3</yellow><yellow>0</yellow>)




  <purple>def</purple> input(key):
      <purple>if</purple> key == <green>'a'</green>:
          <blue>print</blue>(<green>'a'</green>)
          test.text = <green>'&ltdefault&gt&ltimage:file_icon&gt &ltred&gt&ltimage:file_icon&gt test '</green>
          <blue>print</blue>(<green>'by'</green>, test.text)

      <purple>if</purple> key == <green>'c'</green>:
          test.text = <green>''</green>
  window.fps_counter.enabled = False
  <blue>print</blue>(<green>'....'</green>, Text.get_width(<green>'yolo'</green>))
  app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Audio">
        <h1>Audio<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/audio.py"><gray>ursina/audio</gray></a><br><br>
        <div class="params">Audio(sound_file_name='', volume=1, pitch=1, balance=0, loop=False, loops=1, autoplay=True, auto_destroy=False, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>Audio.volume_multiplier = .5  #</td><td></td>
            </tr>
            <tr>
                <td>.clip<gray> = sound_file_name</gray></td><td></td>
            </tr>
            <tr>
                <td>.volume<gray> = volume</gray></td><td></td>
            </tr>
            <tr>
                <td>.pitch<gray> = pitch</gray></td><td></td>
            </tr>
            <tr>
                <td>.balance<gray> = balance</gray></td><td></td>
            </tr>
            <tr>
                <td>.loop<gray> = loop</gray></td><td></td>
            </tr>
            <tr>
                <td>.autoplay<gray> = autoplay</gray></td><td></td>
            </tr>
            <tr>
                <td>.auto_destroy<gray> = auto_destroy</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.volume</td><td><span></span></td>
            </tr>
            <tr>
                <td>.pitch</td><td><span></span></td>
            </tr>
            <tr>
                <td>.loop</td><td><span></span></td>
            </tr>
            <tr>
                <td>.loops</td><td><span></span></td>
            </tr>
            <tr>
                <td>.clip</td><td><span></span></td>
            </tr>
            <tr>
                <td>.length</td><td><span>get the duration of the audio clip.</span></td>
            </tr>
            <tr>
                <td>.status</td><td><span></span></td>
            </tr>
            <tr>
                <td>.ready</td><td><span></span></td>
            </tr>
            <tr>
                <td>.playing</td><td><span></span></td>
            </tr>
            <tr>
                <td>.time</td><td><span></span></td>
            </tr>
            <tr>
                <td>.balance</td><td><span>pan the audio. should be a value between -.5 and .5. default: 0</span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;play(<gray>start=0</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;pause()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;resume()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;stop(<gray>destroy=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;fade(<gray>value, duration=.5, delay=0, curve=curve.in_expo, resolution=None, interrupt=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;fade_in(<gray>value=1, duration=.5, delay=0, curve=curve.in_expo, resolution=None, interrupt='finish',</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;fade_out(<gray>value=0, duration=.5, delay=0, curve=curve.in_expo, resolution=None, interrupt='finish',</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Audio_example)">copy</button><p id="Audio_example"><purple>from</purple> ursina <purple>import</purple> Ursina
<purple>import</purple> random

app = Ursina()
a = <purple><b>Audio</b></purple>(<green>'sine'</green>, loop=True, autopla<olive>y</olive>=True)

a.volume = .<yellow>5</yellow>
<blue>print</blue>(<green>'---'</green>, a.volume)
<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'space'</green>:
        a = <purple><b>Audio</b></purple>(<green>'sine'</green>, pitch=random.uniform(.<yellow>5</yellow>,<yellow>1</yellow>), loop=True)


app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="camera">
        <h1>camera</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/camera.py"><gray>ursina/camera</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>.parent<gray> = scene</gray></td><td></td>
            </tr>
            <tr>
                <td>.name<gray> = 'camera'</gray></td><td></td>
            </tr>
            <tr>
                <td>.eternal<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.ui_size<gray> = 40</gray></td><td></td>
            </tr>
            <tr>
                <td>.perspective_lens_node<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.orthographic_lens_node<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.ui<gray> = Entity(eternal=True, name='ui', scale=(self.ui_size*.5, self.ui_size*.5), add_to_scene_entities=False)</gray></td><td></td>
            </tr>
            <tr>
                <td>.overlay<gray> = Entity(parent=self.ui, model='quad', scale=99, color=color.clear, eternal=True, z=-99, add_to_scene_entities=False)</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.orthographic</td><td><span></span></td>
            </tr>
            <tr>
                <td>.fov</td><td><span></span></td>
            </tr>
            <tr>
                <td>.clip_plane_near</td><td><span></span></td>
            </tr>
            <tr>
                <td>.clip_plane_far</td><td><span></span></td>
            </tr>
            <tr>
                <td>.aspect_ratio</td><td><span>get current aspect ratio. can not be set.</span></td>
            </tr>
            <tr>
                <td>.shader</td><td><span>for applying post-processing effects.</span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;set_up()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;set_shader_input(<gray>name, value</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(camera_example)">copy</button><p id="camera_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, camera, <olive>Entity</olive>, EditorCamera

app = Ursina()

camera.orthographic = True

e = <olive>Entity</olive>()
e.model = <green>'quad'</green>
e.color = color.random_color()
e.position = (-<yellow>2</yellow>, <yellow>0</yellow>, <yellow>1</yellow><yellow>0</yellow>)

e = <olive>Entity</olive>()
e.model = <green>'quad'</green>
e.color = color.random_color()
e.position = (<yellow>2</yellow>, <yellow>0</yellow>, <yellow>1</yellow><yellow>0</yellow>)

e = <olive>Entity</olive>()
e.model = <green>'quad'</green>
e.color = color.random_color()
e.position = (<yellow>0</yellow>, <yellow>0</yellow>, <yellow>4</yellow><yellow>0</yellow>)

Editor<purple><b>Camera</b></purple>()
<purple>from</purple> ursina.shaders <purple>import</purple> camera_grayscale_shader
camera.shader = camera_grayscale_shader

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="mouse">
        <h1>mouse</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/mouse.py"><gray>ursina/mouse</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>.enabled<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.visible<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.locked<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.position<gray> = Vec3(0,0,0)</gray></td><td></td>
            </tr>
            <tr>
                <td>.delta<gray> = Vec3(0,0,0)    </gray></td><td><span>movement since you pressed a mouse button.</span></td>
            </tr>
            <tr>
                <td>.prev_x<gray> = 0</gray></td><td></td>
            </tr>
            <tr>
                <td>.prev_y<gray> = 0</gray></td><td></td>
            </tr>
            <tr>
                <td>.start_x<gray> = 0</gray></td><td></td>
            </tr>
            <tr>
                <td>.start_y<gray> = 0</gray></td><td></td>
            </tr>
            <tr>
                <td>.velocity<gray> = Vec3(0,0,0)</gray></td><td></td>
            </tr>
            <tr>
                <td>.moving<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.prev_click_time<gray> = time.time()</gray></td><td></td>
            </tr>
            <tr>
                <td>.prev_click_pos<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.double_click_distance<gray> = .5</gray></td><td></td>
            </tr>
            <tr>
                <td>.double_click_movement_limit<gray> = .01</gray></td><td></td>
            </tr>
            <tr>
                <td>.hovered_entity<gray> = None </gray></td><td><span>returns the closest hovered entity with a collider.</span></td>
            </tr>
            <tr>
                <td>.left<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.right<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.middle<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.delta_drag<gray> = Vec3(0,0,0)   </gray></td><td><span>movement between left mouse down and left mouse up.</span></td>
            </tr>
            <tr>
                <td>.update_step<gray> = 1</gray></td><td></td>
            </tr>
            <tr>
                <td>.traverse_target<gray> = scene  </gray></td><td><span>set this to None to disable collision with scene, which might be a good idea if you have lots of colliders.</span></td>
            </tr>
            <tr>
                <td>.raycast<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.collision<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.collisions<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.enabled<gray> = True</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.x</td><td><span></span></td>
            </tr>
            <tr>
                <td>.y</td><td><span></span></td>
            </tr>
            <tr>
                <td>.position</td><td><span></span></td>
            </tr>
            <tr>
                <td>.locked</td><td><span></span></td>
            </tr>
            <tr>
                <td>.visible</td><td><span></span></td>
            </tr>
            <tr>
                <td>.normal</td><td><span>returns the normal of the polygon, in local space.</span></td>
            </tr>
            <tr>
                <td>.world_normal</td><td><span>returns the normal of the polygon, in world space.</span></td>
            </tr>
            <tr>
                <td>.point</td><td><span>returns the point hit, in local space</span></td>
            </tr>
            <tr>
                <td>.world_point</td><td><span>returns the point hit, in world space</span></td>
            </tr>
            <tr>
                <td>.is_outside</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;find_collision()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;unhover_everything_not_hit()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(mouse_example)">copy</button><p id="mouse_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, Button, mouse
app = Ursina()
Button(<olive>parent</olive>=scene, <olive>text</olive>=<green>'a'</green>)

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'space'</green>:
        mouse.locked = <purple>not</purple> mouse.locked
        <blue>print</blue>(mouse.velocity)

Cursor()


app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="window">
        <h1>window</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/window.py"><gray>ursina/window</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>.title<gray> = title</gray></td><td></td>
            </tr>
            <tr>
                <td>.icon<gray> = icon</gray></td><td></td>
            </tr>
            <tr>
                <td>.monitors<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.main_monitor<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.monitor_index<gray> = 0</gray></td><td></td>
            </tr>
            <tr>
                <td>.windowed_position<gray> = None   </gray></td><td><span>gets set when entering fullscreen so position will be correct when going back to windowed mode</span></td>
            </tr>
            <tr>
                <td>.show_ursina_splash<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.top<gray> = Vec2(0, .5)</gray></td><td></td>
            </tr>
            <tr>
                <td>.bottom<gray> = Vec2(0, -.5)</gray></td><td></td>
            </tr>
            <tr>
                <td>.center<gray> = Vec2(0, 0)</gray></td><td></td>
            </tr>
            <tr>
                <td>.forced_aspect_ratio<gray> = None </gray></td><td><span>example: window.forced_aspect_ratio</span></td>
            </tr>
            <tr>
                <td>.always_on_top<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.vsync<gray> = True   </gray></td><td><span>can't be set during play</span></td>
            </tr>
            <tr>
                <td>.color<gray> = color.dark_gray</gray></td><td></td>
            </tr>
            <tr>
                <td>.render_modes<gray> = ('default', 'wireframe', 'colliders', 'normals')</gray></td><td></td>
            </tr>
            <tr>
                <td>.render_mode<gray> = 'default'</gray></td><td></td>
            </tr>
            <tr>
                <td>.editor_ui<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.position<gray> = Vec2(x,y)</gray></td><td></td>
            </tr>
            <tr>
                <td>.editor_ui<gray> = Entity(parent=camera.ui, eternal=True, enabled=bool(application.development_mode))</gray></td><td></td>
            </tr>
            <tr>
                <td>.input_entity<gray> = Entity(name='window.input_entity', input=window_input, ignore_paused=True)</gray></td><td></td>
            </tr>
            <tr>
                <td>.exit_button<gray> = Button(parent=self.editor_ui, text='x', eternal=True, ignore_paused=True, origin=(.5, .5), enabled=self.borderless and application.development_mode, position=self.top_right, z=-999, scale=(.05, .025), color=color.red.tint(-.2), shortcuts=('control+shift+alt+q', 'alt+f4'), on_click=application.quit, name='exit_button')</gray></td><td></td>
            </tr>
            <tr>
                <td>.fps_counter<gray> = Text(parent=self.editor_ui, eternal=True, text='60', ignore=False, i=0, ignore_paused=True,
        position=((.5*self.aspect_ratio)-self.exit_button.scale_x, .47+(.02*(not self.exit_button.enabled)), -999))</gray></td><td></td>
            </tr>
            <tr>
                <td>.entity_counter<gray> = Text(parent=self.editor_ui, enabled=application.development_mode, eternal=True, origin=(-.5,.5), text='00', ignore=False, t=0,
        position=((.5*self.aspect_ratio)-self.exit_button.scale_x, .425+(.02*(not self.exit_button.enabled)), -999))</gray></td><td></td>
            </tr>
            <tr>
                <td>.collider_counter<gray> = Text(parent=self.editor_ui, enabled=application.development_mode, eternal=True, origin=(-.5,.5), text='00', ignore=False, t=.1,
        position=((.5*self.aspect_ratio)-self.exit_button.scale_x, .38+(.02*(not self.exit_button.enabled)), -999))</gray></td><td></td>
            </tr>
            <tr>
                <td>.cog_menu<gray> = ButtonList({
        'API Reference' : Func(webbrowser.open, 'https://www.ursinaengine.org/api_reference.html'),
        'ursfx (Sound Effect Maker)' : lambda: exec('from ursina.prefabs import ursfx; ursfx.open_gui()'),
        'Change Render Mode &ltgray&gt[F10]&ltdefault&gt' : self.next_render_mode,
        'Reset Render Mode &ltgray&gt[Shift+F10]&ltdefault&gt' : Func(setattr, self, 'render_mode', 'default'),
        'Toggle Editor Camera &ltgray&gt[Control+F10]&ltdefault&gt' : self.toggle_editor_camera,
        'Toggle Hotreloading &ltgray&gt[F9]&ltdefault&gt' : application.hot_reloader.toggle_hotreloading,
        'Reload Shaders &ltgray&gt[F7]&ltdefault&gt' : application.hot_reloader.reload_shaders,
        'Reload Models &ltgray&gt[F7]&ltdefault&gt' : application.hot_reloader.reload_models,
        'Reload Textures &ltgray&gt[F6]&ltdefault&gt' : application.hot_reloader.reload_textures,
        'Reload Code &ltgray&gt[F5]&ltdefault&gt' : application.hot_reloader.reload_code,</gray></td><td></td>
            </tr>
            <tr>
                <td>.cog_button<gray> = Button(parent=self.editor_ui, eternal=True, model='quad', texture='cog', scale=.015, origin=(1,-1), position=self.bottom_right, ignore_paused=True, name='cog_button', enabled=application.development_mode)</gray></td><td></td>
            </tr>
            <tr>
                <td>.prev_size<gray> = self.size</gray></td><td></td>
            </tr>
            <tr>
                <td>.size<gray> = self.size</gray></td><td></td>
            </tr>
            <tr>
                <td>.render_mode<gray> = self.render_modes[i]</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.left</td><td><span></span></td>
            </tr>
            <tr>
                <td>.right</td><td><span></span></td>
            </tr>
            <tr>
                <td>.top_left</td><td><span></span></td>
            </tr>
            <tr>
                <td>.top_right</td><td><span></span></td>
            </tr>
            <tr>
                <td>.bottom_left</td><td><span></span></td>
            </tr>
            <tr>
                <td>.bottom_right</td><td><span></span></td>
            </tr>
            <tr>
                <td>.position</td><td><span></span></td>
            </tr>
            <tr>
                <td>.size</td><td><span></span></td>
            </tr>
            <tr>
                <td>.aspect_ratio</td><td><span></span></td>
            </tr>
            <tr>
                <td>.forced_aspect_ratio</td><td><span></span></td>
            </tr>
            <tr>
                <td>.render_mode</td><td><span></span></td>
            </tr>
            <tr>
                <td>.title</td><td><span></span></td>
            </tr>
            <tr>
                <td>.icon</td><td><span></span></td>
            </tr>
            <tr>
                <td>.borderless</td><td><span></span></td>
            </tr>
            <tr>
                <td>.fullscreen</td><td><span></span></td>
            </tr>
            <tr>
                <td>.always_on_top</td><td><span></span></td>
            </tr>
            <tr>
                <td>.color</td><td><span></span></td>
            </tr>
            <tr>
                <td>.vsync</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;ready(<gray>title, icon, borderless, fullscreen, size, forced_aspect_ratio, position, vsync, editor_ui_enabled, window_type, render_mode</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;apply_settings()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;center_on_screen()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;make_editor_gui()</td> <td><span>called by main after setting up camera and application.development_mode</span></td>
            </tr>
            <tr>
                <td> &nbsp;window_input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;update_aspect_ratio()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;next_render_mode()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;toggle_editor_camera()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(window_example)">copy</button><p id="window_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina(
    title=<green>'Ursina'</green>,
    )
button_list = ButtonList(
    {
    <green>'widow.position = Vec2(0,0)'</green>: Func(setattr, window, <green>'position'</green>, Vec2(<yellow>0</yellow>,<yellow>0</yellow>)),
    <green>'widow.size = Vec2(512,512)'</green>: Func(setattr, window, <green>'size'</green>, Vec2(<yellow>5</yellow><yellow>1</yellow><yellow>2</yellow>,<yellow>5</yellow><yellow>1</yellow><yellow>2</yellow>)),
    <green>'widow.center_on_screen()'</green>: window.center_on_screen,

    <green>'widow.borderless = True'</green>: Func(setattr, window, <green>'borderless'</green>, True),
    <green>'widow.borderless = False'</green>: Func(setattr, window, <green>'borderless'</green>, False),

    <green>'widow.fullscreen = True'</green>: Func(setattr, window, <green>'fullscreen'</green>, True),
    <green>'widow.fullscreen = False'</green>: Func(setattr, window, <green>'fullscreen'</green>, False),

    <green>'widow.vsync = True'</green>: Func(setattr, window, <green>'vsync'</green>, True),
    <green>'widow.vsync = False'</green>: Func(setattr, window, <green>'vsync'</green>, False),


    <green>'application.base.win.request_properties(self)'</green>: Func(application.base.win.request_properties, window),

    }, <olive>y</olive>=<yellow>0</yellow>
)
startup_value = Text(<olive>y</olive>=.<yellow>5</yellow>,x=-.<yellow>5</yellow>)
startup_value.text = f<green><green>''</green>'
    position: {window.position}
    size: {window.size}
    aspect_ratio: {window.aspect_ratio}
    window.main_monitor.width: {window.main_monitor.width}
    window.main_monitor.height: {window.main_monitor.height}

<green>''</green>'</green>

position_text = Text(<olive>y</olive>=.<yellow>5</yellow>,)


<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'space'</green>:
        window.center_on_screen()




<olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.green, <olive>collider</olive>=<green>'box'</green>, <olive>texture</olive>=<green>'shore'</green>)
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="application">
        <h1>application</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/application.py"><gray>ursina/application</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>.paused<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.time_scale<gray> = 1</gray></td><td></td>
            </tr>
            <tr>
                <td>.calculate_dt<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.sequences<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.trace_entity_definition<gray> = False </gray></td><td><span>enable to set entity.line_definition</span></td>
            </tr>
            <tr>
                <td>.package_folder<gray> = Path(__file__).parent</gray></td><td></td>
            </tr>
            <tr>
                <td>.blender_paths<gray> = dict()</gray></td><td></td>
            </tr>
            <tr>
                <td>.development_mode<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.window_type<gray> = 'onscreen'</gray></td><td></td>
            </tr>
            <tr>
                <td>.show_ursina_splash<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.ursina_splash<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.gltf_no_srgb<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.scenes_folder<gray> = asset_folder / 'scenes/'</gray></td><td></td>
            </tr>
            <tr>
                <td>.scripts_folder<gray> = asset_folder / 'scripts/'</gray></td><td></td>
            </tr>
            <tr>
                <td>.fonts_folder<gray> = asset_folder / 'fonts/'</gray></td><td></td>
            </tr>
            <tr>
                <td>.compressed_textures_folder<gray> = asset_folder / 'textures_compressed/'</gray></td><td></td>
            </tr>
            <tr>
                <td>.compressed_models_folder<gray> = asset_folder / 'models_compressed/'</gray></td><td></td>
            </tr>
            <tr>
                <td>.base<gray> = None             </gray></td><td><span>this will be set once the Ursina() is created</span></td>
            </tr>
            <tr>
                <td>.hot_reloader<gray> = None     </gray></td><td><span>will be set my main if development_mode</span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;pause()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;resume()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;quit()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;load_settings(<gray>path=asset_folder / 'settings.py'</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>

</div>
<br>
    <div class="class_box" id="scene">
        <h1>scene</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/scene.py"><gray>ursina/scene</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>.entities<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.collidables<gray> = set()</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.fog_color</td><td><span></span></td>
            </tr>
            <tr>
                <td>.fog_density</td><td><span></span></td>
            </tr>
            <tr>
                <td>.children</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;set_up()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;clear()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;fog_density(<gray>value</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(scene_example)">copy</button><p id="scene_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()
e = <olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>color</olive>=color.black, <olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow><yellow>0</yellow>)
EditorCamera()
s = Sky()

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'l'</green>:
        <purple>for</purple> e in scene.entities:
            <blue>print</blue>(e.name)

    <purple>if</purple> key == <green>'d'</green>:
        scene.clear()
        <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>)

scene.fog_density = .1          <gray># sets exponential density</gray>
scene.fog_density = (50, 200)   <gray># sets linear density start and end</gray>

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="color">
        <h1>color</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/color.py"><gray>ursina/color</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>.@deprecated("Use hsv(...) instead of color(...)")</td><td></td>
            </tr>
            <tr>
                <td>.white<gray> =         hsv(0, 0, 1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.smoke<gray> =         hsv(0, 0, 0.96)</gray></td><td></td>
            </tr>
            <tr>
                <td>.light_gray<gray> =    hsv(0, 0, 0.75)</gray></td><td></td>
            </tr>
            <tr>
                <td>.gray<gray> =          hsv(0, 0, 0.5)</gray></td><td></td>
            </tr>
            <tr>
                <td>.dark_gray<gray> =     hsv(0, 0, 0.25)</gray></td><td></td>
            </tr>
            <tr>
                <td>.black<gray> =         hsv(0, 0, 0)</gray></td><td></td>
            </tr>
            <tr>
                <td>.red<gray> =           hsv(0, 1, 1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.yellow<gray> =        hsv(60, 1, 1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.lime<gray> =          hsv(90, 1, 1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.green<gray> =         hsv(120, 1, 1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.turquoise<gray> =     hsv(150, 1, 1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.cyan<gray> =          hsv(180, 1, 1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.azure<gray> =         hsv(210, 1, 1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.blue<gray> =          hsv(240, 1, 1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.violet<gray> =        hsv(270, 1, 1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.magenta<gray> =       hsv(300, 1, 1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.pink<gray> =          hsv(330, 1, 1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.brown<gray> =         rgb32(165, 42, 42)</gray></td><td></td>
            </tr>
            <tr>
                <td>.olive<gray> =         rgb32(128, 128, 0)</gray></td><td></td>
            </tr>
            <tr>
                <td>.peach<gray> =         rgb32(255, 218, 185)</gray></td><td></td>
            </tr>
            <tr>
                <td>.gold<gray> =          rgb32(255, 215, 0)</gray></td><td></td>
            </tr>
            <tr>
                <td>.salmon<gray> =        rgb32(250, 128, 114)</gray></td><td></td>
            </tr>
            <tr>
                <td>.clear<gray> =         rgba(0, 0, 0, 0)</gray></td><td></td>
            </tr>
            <tr>
                <td>.white10<gray> =       rgba(1,1,1, 0.10)</gray></td><td></td>
            </tr>
            <tr>
                <td>.white33<gray> =       rgba(1,1,1, 0.33)</gray></td><td></td>
            </tr>
            <tr>
                <td>.white50<gray> =       rgba(1,1,1, 0.50)</gray></td><td></td>
            </tr>
            <tr>
                <td>.white66<gray> =       rgba(1,1,1, 0.66)</gray></td><td></td>
            </tr>
            <tr>
                <td>.black10<gray> =       rgba(0,0,0, 0.10)</gray></td><td></td>
            </tr>
            <tr>
                <td>.black33<gray> =       rgba(0,0,0, 0.33)</gray></td><td></td>
            </tr>
            <tr>
                <td>.black50<gray> =       rgba(0,0,0, 0.50)</gray></td><td></td>
            </tr>
            <tr>
                <td>.black66<gray> =       rgba(0,0,0, 0.66)</gray></td><td></td>
            </tr>
            <tr>
                <td>.black90<gray> =       rgba(0,0,0, 0.90)</gray></td><td></td>
            </tr>
            <tr>
                <td>.text<gray> = smoke</gray></td><td></td>
            </tr>
            <tr>
                <td>.light_text<gray> = smoke</gray></td><td></td>
            </tr>
            <tr>
                <td>.dark_text<gray> = hsv(0, 0, .1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.text_color<gray> = light_text</gray></td><td></td>
            </tr>
            <tr>
                <td>.color_names<gray> = ('white', 'smoke', 'light_gray', 'gray', 'dark_gray', 'black',</gray></td><td></td>
            </tr>
            <tr>
                <td>.colors<gray> = dict()</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;color(<gray>h,s,v,a=1</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;hsv(<gray>h, s, v, a=1</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;rgba32(<gray>r, g, b, a=255</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;rgb32(<gray>r, g, b</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;rgba(<gray>r, g, b, a</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;rgb(<gray>r, g, b</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;to_hsv(<gray>color</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;hex(<gray>value</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;rgb_to_hex(<gray>r, g, b, a=1</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;brightness(<gray>color</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;inverse(<gray>color</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;random_color()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;tint(<gray>color, amount=.2</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(color_example)">copy</button><p id="color_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, <olive>Entity</olive>, Button, Quad, grid_layout, color
app = Ursina()

<blue>print</blue>(color.brightness(color.blue))

p = <olive>Entity</olive>(x=-<yellow>2</yellow>)
<purple>for</purple> key in color.colors:
    <blue>print</blue>(key)
    b = Button(<olive>parent</olive>=p, <olive>model</olive>=Quad(<yellow>0</yellow>), <olive>color</olive>=color.colors[key], <olive>text</olive>=key)
    b.text_entity.scale *= .<yellow>5</yellow>

grid_layout(p.children, max_x=<yellow>8</yellow>)

<purple>for</purple> name in (<green>'r'</green>, <green>'g'</green>, <green>'b'</green>, <green>'h'</green>, <green>'s'</green>, <green>'v'</green>, <green>'brightness'</green>):
    <blue>print</blue>(name + <green>':'</green>, <blue>getattr</blue>(color.random_<purple><b>color</b></purple>(), name))

e = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.lime)
<blue>print</blue>(e.color.name)
<blue>print</blue>(<green>'rgb to hex:'</green>, color.rgb_to_hex(*color.blue))
e.color = color.<purple><b>color</b></purple>(<yellow>1</yellow>,<yellow>2</yellow>,<yellow>3</yellow>)
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Mesh">
        <h1>Mesh<a style="color: gray; font-weight:normal;" href="#p3d.">(p3d.)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/mesh.py"><gray>ursina/mesh</gray></a><br><br>
        <div class="params">Mesh(vertices=None, triangles=None, colors=None, uvs=None, normals=None, static=True, mode='triangle', thickness=1, render_points_in_3d=True, vertex_buffer=None, vertex_buffer_length=None, vertex_buffer_format=None)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>Mesh.}</td><td></td>
            </tr>
            <tr>
                <td>.vertices<gray> = vertices</gray></td><td></td>
            </tr>
            <tr>
                <td>.triangles<gray> = triangles</gray></td><td></td>
            </tr>
            <tr>
                <td>.colors<gray> = colors</gray></td><td></td>
            </tr>
            <tr>
                <td>.uvs<gray> = uvs</gray></td><td></td>
            </tr>
            <tr>
                <td>.normals<gray> = normals</gray></td><td></td>
            </tr>
            <tr>
                <td>.static<gray> = static</gray></td><td></td>
            </tr>
            <tr>
                <td>.mode<gray> = mode</gray></td><td></td>
            </tr>
            <tr>
                <td>.thickness<gray> = thickness</gray></td><td></td>
            </tr>
            <tr>
                <td>.render_points_in_3d<gray> = render_points_in_3d</gray></td><td></td>
            </tr>
            <tr>
                <td>.vertex_buffer<gray> = vertex_buffer</gray></td><td></td>
            </tr>
            <tr>
                <td>.vertex_buffer_length<gray> = vertex_buffer_length</gray></td><td></td>
            </tr>
            <tr>
                <td>.vertex_buffer_format<gray> = vertex_buffer_format</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.indices</td><td><span></span></td>
            </tr>
            <tr>
                <td>.generated_vertices</td><td><span></span></td>
            </tr>
            <tr>
                <td>.render_points_in_3d</td><td><span></span></td>
            </tr>
            <tr>
                <td>.thickness</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;generate()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;recipe()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;serialize(<gray>vertex_decimal_limit=4, color_decimal_limit=4, uv_decimal_limit=4, normal_decimal_limit=4</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;generate_normals(<gray>smooth=True, regenerate=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;colorize(<gray>left=color.white, right=color.blue, down=color.red, up=color.green, back=color.white, forward=color.white, smooth=True, world_space=True, strength=1</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;project_uvs(<gray>aspect_ratio=1, direction='forward'</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;clear(<gray>regenerate=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;save(<gray>name='', folder:Path=Func(getattr, application, 'compressed_models_folder'), flip_faces=False, vertex_decimal_limit=5, color_decimal_limit=4</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Mesh_example)">copy</button><p id="Mesh_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()

e = <olive>Entity</olive>(<olive>position</olive>=(<yellow>0</yellow>,<yellow>0</yellow>), <olive>model</olive>=<purple><b>Mesh</b></purple>(<olive>vertices</olive>=[(-.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), (.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), (<yellow>0</yellow>, <yellow>1</yellow>, <yellow>0</yellow>)]))

e = <olive>Entity</olive>(<olive>position</olive>=(<yellow>1</yellow>,<yellow>0</yellow>), <olive>model</olive>=<purple><b>Mesh</b></purple>(<olive>vertices</olive>=((-.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), (.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), (<yellow>0</yellow>, <yellow>1</yellow>, <yellow>0</yellow>))))
Text(<olive>parent</olive>=e, <olive>text</olive>=<green>'triangle mesh\nwith verts as tuple of tuples'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))

e = <olive>Entity</olive>(<olive>position</olive>=(<yellow>0</yellow>,-<yellow>2</yellow>), <olive>model</olive>=<purple><b>Mesh</b></purple>(<olive>vertices</olive>=[[-.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>], [.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>], [<yellow>0</yellow>, <yellow>1</yellow>, <yellow>0</yellow>]]))
Text(<olive>parent</olive>=e, <olive>text</olive>=<green>'triangle mesh\nwith verts as list of lists'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))

e = <olive>Entity</olive>(<olive>position</olive>=(<yellow>1</yellow>,-<yellow>2</yellow>), <olive>model</olive>=<purple><b>Mesh</b></purple>(
    <olive>vertices</olive>=([-.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>], [.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>], [<yellow>0</yellow>, <yellow>1</yellow>, <yellow>0</yellow>])
))
Text(<olive>parent</olive>=e, <olive>text</olive>=<green>'triangle mesh\nwith verts as tuple of lists'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))

e = <olive>Entity</olive>(<olive>position</olive>=(<yellow>0</yellow>,-<yellow>4</yellow>), <olive>model</olive>=<purple><b>Mesh</b></purple>(
    <olive>vertices</olive>=[Vec3(-.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), Vec3(.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), Vec3(<yellow>0</yellow>, <yellow>1</yellow>, <yellow>0</yellow>)],
))
Text(<olive>parent</olive>=e, <olive>text</olive>=<green>'triangle mesh\nwith verts as list Vec3'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))


e = <olive>Entity</olive>(<olive>position</olive>=(<yellow>1</yellow>,-<yellow>4</yellow>), <olive>model</olive>=<purple><b>Mesh</b></purple>(
    <olive>vertices</olive>=[Vec3(-.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), Vec3(.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), Vec3(<yellow>0</yellow>, <yellow>1</yellow>, <yellow>0</yellow>)],
    triangles = [<yellow>0</yellow>,<yellow>1</yellow>,<yellow>2</yellow>],
))
Text(<olive>parent</olive>=e, <olive>text</olive>=<green>'triangle mesh\nwith tris as flat list'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))

e = <olive>Entity</olive>(<olive>position</olive>=(<yellow>2</yellow>.<yellow>5</yellow>,<yellow>0</yellow>), <olive>model</olive>=<purple><b>Mesh</b></purple>(
    <olive>vertices</olive>=[Vec3(-.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), Vec3(.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), Vec3(<yellow>0</yellow>, <yellow>1</yellow>, <yellow>0</yellow>)],
    triangles = [(0,1,2), (2,1,0)], <gray># should be double sided</gray>
))
Text(<olive>parent</olive>=e, <olive>text</olive>=<green>'triangle mesh\nwith tris as list of triangles'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))


continious_line = <olive>Entity</olive>(<olive>position</olive>=(<yellow>4</yellow>,<yellow>0</yellow>), <olive>model</olive>=<purple><b>Mesh</b></purple>(
    <olive>vertices</olive>=(Vec3(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), Vec3(.<yellow>6</yellow>,.<yellow>3</yellow>,<yellow>0</yellow>), Vec3(<yellow>1</yellow>,<yellow>1</yellow>,<yellow>0</yellow>), Vec3(.<yellow>6</yellow>,<yellow>1</yellow>.<yellow>7</yellow>,<yellow>0</yellow>), Vec3(<yellow>0</yellow>,<yellow>2</yellow>,<yellow>0</yellow>)),
    <olive>mode</olive>=<green>'line'</green>,
    <olive>thickness</olive>=<yellow>4</yellow>,
    ), <olive>color</olive>=color.cyan)
Text(<olive>parent</olive>=continious_line, <olive>text</olive>=<green>'continious_line'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>)

line_segments = <olive>Entity</olive>(<olive>position</olive>=(<yellow>4</yellow>,-<yellow>2</yellow>), <olive>model</olive>=<purple><b>Mesh</b></purple>(
    <olive>vertices</olive>=(Vec3(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), Vec3(.<yellow>6</yellow>,.<yellow>3</yellow>,<yellow>0</yellow>), Vec3(<yellow>1</yellow>,<yellow>1</yellow>,<yellow>0</yellow>), Vec3(.<yellow>6</yellow>,<yellow>1</yellow>.<yellow>7</yellow>,<yellow>0</yellow>), Vec3(<yellow>0</yellow>,<yellow>2</yellow>,<yellow>0</yellow>)),
    <olive>triangles</olive>= ((<yellow>0</yellow>,<yellow>1</yellow>), (<yellow>3</yellow>,<yellow>4</yellow>)),
    <olive>mode</olive>=<green>'line'</green>,
    <olive>thickness</olive>=<yellow>4</yellow>,
    ), <olive>color</olive>=color.magenta)
Text(<olive>parent</olive>=line_segments, <olive>text</olive>=<green>'line_segments'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>)

points = <olive>Entity</olive>(<olive>position</olive>=(<yellow>6</yellow>,<yellow>0</yellow>), <olive>model</olive>=<purple><b>Mesh</b></purple>(<olive>vertices</olive>=(Vec3(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), Vec3(.<yellow>6</yellow>,.<yellow>3</yellow>,<yellow>0</yellow>), Vec3(<yellow>1</yellow>,<yellow>1</yellow>,<yellow>0</yellow>), Vec3(.<yellow>6</yellow>,<yellow>1</yellow>.<yellow>7</yellow>,<yellow>0</yellow>), Vec3(<yellow>0</yellow>,<yellow>2</yellow>,<yellow>0</yellow>)), <olive>mode</olive>=<green>'point'</green>, <olive>thickness</olive>=.<yellow>0</yellow><yellow>5</yellow>), <olive>color</olive>=color.red)
Text(<olive>parent</olive>=points, <olive>text</olive>=<green>'points'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>)

points_<yellow>2</yellow>d = <olive>Entity</olive>(<olive>position</olive>=(<yellow>6</yellow>,-<yellow>2</yellow>), <olive>model</olive>=<purple><b>Mesh</b></purple>(<olive>vertices</olive>=(Vec3(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), Vec3(.<yellow>6</yellow>,.<yellow>3</yellow>,<yellow>0</yellow>), Vec3(<yellow>1</yellow>,<yellow>1</yellow>,<yellow>0</yellow>), Vec3(.<yellow>6</yellow>,<yellow>1</yellow>.<yellow>7</yellow>,<yellow>0</yellow>), Vec3(<yellow>0</yellow>,<yellow>2</yellow>,<yellow>0</yellow>)), <olive>mode</olive>=<green>'point'</green>, <olive>thickness</olive>=<yellow>1</yellow><yellow>0</yellow>, render_points_in_<yellow>3</yellow>d=False), <olive>color</olive>=color.red)
Text(<olive>parent</olive>=points_<yellow>2</yellow>d, <olive>text</olive>=<green>'points_2d'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>)

quad = <olive>Entity</olive>(
    <olive>position</olive>=(<yellow>8</yellow>,<yellow>0</yellow>),
    <olive>model</olive>=<purple><b>Mesh</b></purple>(
        <olive>vertices</olive>=((<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>)),
        <olive>uvs</olive>=((<yellow>1</yellow>, <yellow>1</yellow>), (<yellow>0</yellow>, <yellow>1</yellow>), (<yellow>0</yellow>, <yellow>0</yellow>), (<yellow>1</yellow>, <yellow>0</yellow>), (<yellow>1</yellow>, <yellow>1</yellow>), (<yellow>0</yellow>, <yellow>0</yellow>)),
        <olive>mode</olive>=<green>'triangle'</green>),
    <olive>texture</olive>=<green>'shore'</green>
    )
Text(<olive>parent</olive>=quad, <olive>text</olive>=<green>'quad_with_uvs'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))

quad = <olive>Entity</olive>(
    <olive>position</olive>=(<yellow>8</yellow>,-<yellow>2</yellow>),
    <olive>model</olive>=<purple><b>Mesh</b></purple>(
        <olive>vertices</olive>=((<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>)),
        <olive>uvs</olive>=((<yellow>1</yellow>, <yellow>1</yellow>), (<yellow>0</yellow>, <yellow>1</yellow>), (<yellow>0</yellow>, <yellow>0</yellow>), (<yellow>1</yellow>, <yellow>0</yellow>), (<yellow>1</yellow>, <yellow>1</yellow>), (<yellow>0</yellow>, <yellow>0</yellow>)),
        <olive>normals</olive>=[(-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>)],
        <olive>mode</olive>=<green>'triangle'</green>),
    )
Text(<olive>parent</olive>=quad, <olive>text</olive>=<green>'quad_with_normals'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))

quad = <olive>Entity</olive>(
    <olive>position</olive>=(<yellow>8</yellow>,-<yellow>4</yellow>),
    <olive>model</olive>=<purple><b>Mesh</b></purple>(
        <olive>vertices</olive>=((<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>)),
        <olive>uvs</olive>=((<yellow>1</yellow>, <yellow>1</yellow>), (<yellow>0</yellow>, <yellow>1</yellow>), (<yellow>0</yellow>, <yellow>0</yellow>), (<yellow>1</yellow>, <yellow>0</yellow>), (<yellow>1</yellow>, <yellow>1</yellow>), (<yellow>0</yellow>, <yellow>0</yellow>)),
        <olive>normals</olive>=[(-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>)],
        <olive>mode</olive>=<green>'triangle'</green>),
    )
Text(<olive>parent</olive>=quad, <olive>text</olive>=<green>'quad_with_usv_and_normals'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))

quad = <olive>Entity</olive>(
    <olive>position</olive>=(<yellow>8</yellow>,-<yellow>6</yellow>),
    <olive>model</olive>=<purple><b>Mesh</b></purple>(
        <olive>vertices</olive>=((<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>)),
        <olive>uvs</olive>=((<yellow>1</yellow>, <yellow>1</yellow>), (<yellow>0</yellow>, <yellow>1</yellow>), (<yellow>0</yellow>, <yellow>0</yellow>), (<yellow>1</yellow>, <yellow>0</yellow>), (<yellow>1</yellow>, <yellow>1</yellow>), (<yellow>0</yellow>, <yellow>0</yellow>)),
        <olive>normals</olive>=[(-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>0</yellow>, <yellow>0</yellow>.<yellow>0</yellow>, -<yellow>1</yellow>.<yellow>0</yellow>)],
        <olive>colors</olive>=[color.red, color.yellow, color.green, color.cyan, color.blue, color.magenta],
        <olive>mode</olive>=<green>'triangle'</green>),
    )
Text(<olive>parent</olive>=quad, <olive>text</olive>=<green>'quad_with_usv_and_normals_and_vertex_colors'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))

quad = <olive>Entity</olive>(
    <olive>position</olive>=(<yellow>1</yellow><yellow>0</yellow>,<yellow>0</yellow>),
    <olive>model</olive>=<purple><b>Mesh</b></purple>(
        <olive>vertices</olive>=((-<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>)),
        <olive>triangles</olive>=(<yellow>0</yellow>,<yellow>1</yellow>,<yellow>2</yellow>, <yellow>2</yellow>,<yellow>3</yellow>,<yellow>0</yellow>),
        <olive>mode</olive>=<green>'triangle'</green>),
    )
Text(<olive>parent</olive>=quad, <olive>text</olive>=<green>'triangles flat'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))

quad = <olive>Entity</olive>(
    <olive>position</olive>=(<yellow>1</yellow><yellow>0</yellow>,-<yellow>2</yellow>),
    <olive>model</olive>=<purple><b>Mesh</b></purple>(
        <olive>vertices</olive>=((-<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>)),
        <olive>triangles</olive>=((<yellow>0</yellow>,<yellow>1</yellow>,<yellow>2</yellow>), (<yellow>2</yellow>,<yellow>3</yellow>,<yellow>0</yellow>)),
        <olive>mode</olive>=<green>'triangle'</green>),
    )
Text(<olive>parent</olive>=quad, <olive>text</olive>=<green>'triangles triplets'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))

quad = <olive>Entity</olive>(
    <olive>position</olive>=(<yellow>1</yellow><yellow>0</yellow>,-<yellow>4</yellow>),
    <olive>model</olive>=<purple><b>Mesh</b></purple>(
        <olive>vertices</olive>=((-<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (<yellow>0</yellow>.<yellow>5</yellow>, -<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>), (-<yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>5</yellow>, <yellow>0</yellow>.<yellow>0</yellow>)),
        <olive>triangles</olive>=((<yellow>0</yellow>,<yellow>1</yellow>,<yellow>2</yellow>,<yellow>3</yellow>), (<yellow>0</yellow>,<yellow>3</yellow>,<yellow>2</yellow>)),
        <olive>mode</olive>=<green>'triangle'</green>),
    )
Text(<olive>parent</olive>=quad, <olive>text</olive>=<green>'triangles quad + tri'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))

copy_test = <olive>Entity</olive>(<olive>position</olive>=(<yellow>1</yellow><yellow>2</yellow>,<yellow>0</yellow>), <olive>model</olive>=copy(quad.model))
Text(<olive>parent</olive>=copy_test, <olive>text</olive>=<green>'copy_test'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))

deepcopy_test = <olive>Entity</olive>(<olive>position</olive>=(<yellow>1</yellow><yellow>2</yellow>,-<yellow>2</yellow>), <olive>model</olive>=deepcopy(quad.model))
Text(<olive>parent</olive>=deepcopy_test, <olive>text</olive>=<green>'deepcopy_test'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))

clear_test = <olive>Entity</olive>(<olive>position</olive>=(<yellow>1</yellow><yellow>2</yellow>,-<yellow>4</yellow>), <olive>model</olive>=deepcopy(quad.model))
clear_test.model.clear()
Text(<olive>parent</olive>=clear_test, <olive>text</olive>=<green>'.clear() test'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>scale</olive>=<yellow>5</yellow>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>))


window.color = color.black
EditorCamera()

<blue>print</blue>(load_model(<green>'sphere'</green>, application.internal_models_compressed_folder, use_deepcop<olive>y</olive>=True).serialize())
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Shader">
        <h1>Shader</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shader.py"><gray>ursina/shader</gray></a><br><br>
        <div class="params">Shader(name='untitled_shader', language=GLSL, vertex=default_vertex_shader, fragment=default_fragment_shader, geometry='', **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>Shader.CG = Panda3dShader.SL_Cg</td><td></td>
            </tr>
            <tr>
                <td>Shader.GLSL = Panda3dShader.SL_GLSL</td><td></td>
            </tr>
            <tr>
                <td>Shader.HLSL = Panda3dShader.SL_HLSL</td><td></td>
            </tr>
            <tr>
                <td>Shader.SPIR_V = Panda3dShader.SL_SPIR_V</td><td></td>
            </tr>
            <tr>
                <td>.name<gray> = name</gray></td><td></td>
            </tr>
            <tr>
                <td>.language<gray> = language</gray></td><td></td>
            </tr>
            <tr>
                <td>.vertex<gray> = vertex</gray></td><td></td>
            </tr>
            <tr>
                <td>.fragment<gray> = fragment</gray></td><td></td>
            </tr>
            <tr>
                <td>.geometry<gray> = geometry</gray></td><td></td>
            </tr>
            <tr>
                <td>.default_input<gray> = dict()</gray></td><td></td>
            </tr>
            <tr>
                <td>.continuous_input<gray> = dict()</gray></td><td></td>
            </tr>
            <tr>
                <td>.compiled<gray> = False</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;compile(<gray>shader_includes=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;load(<gray>cls, language=Panda3dShader.SL_GLSL, vertex=None, fragment=None, geometry=None, **kwargs</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Shader_example)">copy</button><p id="Shader_example"><purple>from</purple> time <purple>import</purple> perf_counter
t = perf_counter()
<purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, <olive>Entity</olive>, held_keys, scene, EditorCamera

app = Ursina()
<olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>shader</olive>=<purple><b>Shader</b></purple>())
EditorCamera()
<blue>print</blue>(<green>'ttttttttttttt'</green>, perf_counter() - t)
<purple>def</purple> input(key):
    <purple>if</purple> held_keys[<green>'control'</green>] and key == <green>'r'</green>:
        reload_shaders()

<purple>def</purple> reload_shaders():
    <purple>for</purple> e in scene.entities:
        <purple>if</purple> <blue>hasattr</blue>(e, <green>'_shader'</green>):
            <blue>print</blue>(<green>'-------'</green>, e.shader)

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Texture">
        <h1>Texture</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/texture.py"><gray>ursina/texture</gray></a><br><br>
        <div class="params">Texture(value, filtering='default')</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.filtering<gray> = filtering</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.name</td><td><span></span></td>
            </tr>
            <tr>
                <td>.size</td><td><span></span></td>
            </tr>
            <tr>
                <td>.width</td><td><span></span></td>
            </tr>
            <tr>
                <td>.height</td><td><span></span></td>
            </tr>
            <tr>
                <td>.pixels</td><td><span></span></td>
            </tr>
            <tr>
                <td>.filtering</td><td><span></span></td>
            </tr>
            <tr>
                <td>.repeat</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;new(<gray>size, color=(255,255,255)</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;get_pixel(<gray>x, y</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;get_pixels(<gray>start, end</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;set_pixel(<gray>x, y, color</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;apply()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;save(<gray>path</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Texture_example)">copy</button><p id="Texture_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> texture_importer
app = Ursina()
<green><green>''</green>'
    The Texture class rarely used manually but usually instantiated
    when assigning a texture to an Entity
    texture = <b>Texture</b>(path / PIL.Image / panda3d.core.Texture)

    A texture file can be a .png, .jpg or .psd.
    If it's a .psd it and no compressed version exists, it will compress it automatically.
<green>''</green>'</green>
e = <olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>, <olive>texture</olive>=<green>'brick'</green>)
e.texture.set_pixel(<yellow>0</yellow>, <yellow>2</yellow>, color.blue)
e.texture.apply()</p>
</div>

</div>
<br>
    <div class="class_box" id="Light">
        <h1>Light<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/lights.py"><gray>ursina/lights</gray></a><br><br>
        <div class="params">Light(**kwargs)</div><br>
        <table> <!-- attributes -->
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.color</td><td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Light_example)">copy</button><p id="Light_example"><purple>from</purple> ursina <purple>import</purple> Ursina, EditorCamera, color, Vec<yellow>3</yellow>

app = Ursina()
from ursina.shaders import lit_with_shadows_shader <gray># you have to apply this shader to enties for them to receive shadows.</gray>
EditorCamera()
<olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>, <olive>color</olive>=color.gray, <olive>shader</olive>=lit_with_shadows_shader)
<olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>shader</olive>=lit_with_shadows_shader, <olive>color</olive>=color.light_gray)
light = Directional<purple><b>Light</b></purple>(shadows=True)
light.look_at(Vec3(<yellow>1</yellow>,-<yellow>1</yellow>,<yellow>1</yellow>))

dont_cast_shadow = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>shader</olive>=lit_with_shadows_shader, x=<yellow>2</yellow>, <olive>color</olive>=color.light_gray)
dont_cast_shadow.hide(<yellow>0</yellow>b<yellow>0</yellow><yellow>0</yellow><yellow>0</yellow><yellow>1</yellow>)

unlit_entity = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>,x=-<yellow>2</yellow>, unlit=True, <olive>color</olive>=color.light_gray)

bar = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>position</olive>=(<yellow>0</yellow>,<yellow>3</yellow>,-<yellow>2</yellow>), <olive>shader</olive>=lit_with_shadows_shader, <olive>scale</olive>=(<yellow>1</yellow><yellow>0</yellow>,.<yellow>2</yellow>,.<yellow>2</yellow>), <olive>color</olive>=color.light_gray)

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="DirectionalLight">
        <h1>DirectionalLight<a style="color: gray; font-weight:normal;" href="#Light">(Light)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/lights.py"><gray>ursina/lights</gray></a><br><br>
        <div class="params">DirectionalLight(shadows=True, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.shadow_map_resolution<gray> = Vec2(1024, 1024)</gray></td><td></td>
            </tr>
            <tr>
                <td>.shadows<gray> = shadows</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.shadows</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;update_bounds(<gray>entity=scene</gray>)</td> <td><span>update the shadow area to fit the bounds of target entity, defaulted to scene.</span></td>
            </tr>
            <tr>
                <td> &nbsp;look_at(<gray>target, axis='forward', up=None</gray>)</td> <td><span>up defaults to self.up</span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(DirectionalLight_example)">copy</button><p id="DirectionalLight_example"><purple>from</purple> ursina <purple>import</purple> Ursina, EditorCamera, color, Vec<yellow>3</yellow>

app = Ursina()
from ursina.shaders import lit_with_shadows_shader <gray># you have to apply this shader to enties for them to receive shadows.</gray>
EditorCamera()
<olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>, <olive>color</olive>=color.gray, <olive>shader</olive>=lit_with_shadows_shader)
<olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>shader</olive>=lit_with_shadows_shader, <olive>color</olive>=color.light_gray)
light = <purple><b>DirectionalLight</b></purple>(shadows=True)
light.look_at(Vec3(<yellow>1</yellow>,-<yellow>1</yellow>,<yellow>1</yellow>))

dont_cast_shadow = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>shader</olive>=lit_with_shadows_shader, x=<yellow>2</yellow>, <olive>color</olive>=color.light_gray)
dont_cast_shadow.hide(<yellow>0</yellow>b<yellow>0</yellow><yellow>0</yellow><yellow>0</yellow><yellow>1</yellow>)

unlit_entity = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>,x=-<yellow>2</yellow>, unlit=True, <olive>color</olive>=color.light_gray)

bar = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>position</olive>=(<yellow>0</yellow>,<yellow>3</yellow>,-<yellow>2</yellow>), <olive>shader</olive>=lit_with_shadows_shader, <olive>scale</olive>=(<yellow>1</yellow><yellow>0</yellow>,.<yellow>2</yellow>,.<yellow>2</yellow>), <olive>color</olive>=color.light_gray)

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="PointLight">
        <h1>PointLight<a style="color: gray; font-weight:normal;" href="#Light">(Light)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/lights.py"><gray>ursina/lights</gray></a><br><br>
        <div class="params">PointLight(**kwargs)</div><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(PointLight_example)">copy</button><p id="PointLight_example"><purple>from</purple> ursina <purple>import</purple> Ursina, EditorCamera, color, Vec<yellow>3</yellow>

app = Ursina()
from ursina.shaders import lit_with_shadows_shader <gray># you have to apply this shader to enties for them to receive shadows.</gray>
EditorCamera()
<olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>, <olive>color</olive>=color.gray, <olive>shader</olive>=lit_with_shadows_shader)
<olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>shader</olive>=lit_with_shadows_shader, <olive>color</olive>=color.light_gray)
light = DirectionalLight(shadows=True)
light.look_at(Vec3(<yellow>1</yellow>,-<yellow>1</yellow>,<yellow>1</yellow>))

dont_cast_shadow = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>shader</olive>=lit_with_shadows_shader, x=<yellow>2</yellow>, <olive>color</olive>=color.light_gray)
dont_cast_shadow.hide(<yellow>0</yellow>b<yellow>0</yellow><yellow>0</yellow><yellow>0</yellow><yellow>1</yellow>)

unlit_entity = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>,x=-<yellow>2</yellow>, unlit=True, <olive>color</olive>=color.light_gray)

bar = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>position</olive>=(<yellow>0</yellow>,<yellow>3</yellow>,-<yellow>2</yellow>), <olive>shader</olive>=lit_with_shadows_shader, <olive>scale</olive>=(<yellow>1</yellow><yellow>0</yellow>,.<yellow>2</yellow>,.<yellow>2</yellow>), <olive>color</olive>=color.light_gray)

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="AmbientLight">
        <h1>AmbientLight<a style="color: gray; font-weight:normal;" href="#Light">(Light)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/lights.py"><gray>ursina/lights</gray></a><br><br>
        <div class="params">AmbientLight(**kwargs)</div><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(AmbientLight_example)">copy</button><p id="AmbientLight_example"><purple>from</purple> ursina <purple>import</purple> Ursina, EditorCamera, color, Vec<yellow>3</yellow>

app = Ursina()
from ursina.shaders import lit_with_shadows_shader <gray># you have to apply this shader to enties for them to receive shadows.</gray>
EditorCamera()
<olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>, <olive>color</olive>=color.gray, <olive>shader</olive>=lit_with_shadows_shader)
<olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>shader</olive>=lit_with_shadows_shader, <olive>color</olive>=color.light_gray)
light = DirectionalLight(shadows=True)
light.look_at(Vec3(<yellow>1</yellow>,-<yellow>1</yellow>,<yellow>1</yellow>))

dont_cast_shadow = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>shader</olive>=lit_with_shadows_shader, x=<yellow>2</yellow>, <olive>color</olive>=color.light_gray)
dont_cast_shadow.hide(<yellow>0</yellow>b<yellow>0</yellow><yellow>0</yellow><yellow>0</yellow><yellow>1</yellow>)

unlit_entity = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>,x=-<yellow>2</yellow>, unlit=True, <olive>color</olive>=color.light_gray)

bar = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>position</olive>=(<yellow>0</yellow>,<yellow>3</yellow>,-<yellow>2</yellow>), <olive>shader</olive>=lit_with_shadows_shader, <olive>scale</olive>=(<yellow>1</yellow><yellow>0</yellow>,.<yellow>2</yellow>,.<yellow>2</yellow>), <olive>color</olive>=color.light_gray)

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="SpotLight">
        <h1>SpotLight<a style="color: gray; font-weight:normal;" href="#Light">(Light)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/lights.py"><gray>ursina/lights</gray></a><br><br>
        <div class="params">SpotLight(**kwargs)</div><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(SpotLight_example)">copy</button><p id="SpotLight_example"><purple>from</purple> ursina <purple>import</purple> Ursina, EditorCamera, color, Vec<yellow>3</yellow>

app = Ursina()
from ursina.shaders import lit_with_shadows_shader <gray># you have to apply this shader to enties for them to receive shadows.</gray>
EditorCamera()
<olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>, <olive>color</olive>=color.gray, <olive>shader</olive>=lit_with_shadows_shader)
<olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>shader</olive>=lit_with_shadows_shader, <olive>color</olive>=color.light_gray)
light = DirectionalLight(shadows=True)
light.look_at(Vec3(<yellow>1</yellow>,-<yellow>1</yellow>,<yellow>1</yellow>))

dont_cast_shadow = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>, <olive>shader</olive>=lit_with_shadows_shader, x=<yellow>2</yellow>, <olive>color</olive>=color.light_gray)
dont_cast_shadow.hide(<yellow>0</yellow>b<yellow>0</yellow><yellow>0</yellow><yellow>0</yellow><yellow>1</yellow>)

unlit_entity = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=<yellow>1</yellow>,x=-<yellow>2</yellow>, unlit=True, <olive>color</olive>=color.light_gray)

bar = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>position</olive>=(<yellow>0</yellow>,<yellow>3</yellow>,-<yellow>2</yellow>), <olive>shader</olive>=lit_with_shadows_shader, <olive>scale</olive>=(<yellow>1</yellow><yellow>0</yellow>,.<yellow>2</yellow>,.<yellow>2</yellow>), <olive>color</olive>=color.light_gray)

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Circle">
        <h1>Circle<a style="color: gray; font-weight:normal;" href="#Mesh">(Mesh)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/models/procedural/circle.py"><gray>ursina/models/procedural/circle</gray></a><br><br>
        <div class="params">Circle(resolution=16, radius=.5, mode='ngon', **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.vertices<gray> = list()</gray></td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Circle_example)">copy</button><p id="Circle_example">app = Ursina()
e = <olive>Entity</olive>(<olive>model</olive>=<purple><b>Circle</b></purple>(<yellow>8</yellow>, <olive>mode</olive>=<green>'line'</green>, <olive>thickness</olive>=<yellow>1</yellow><yellow>0</yellow>), <olive>color</olive>=color.hsv(<yellow>6</yellow><yellow>0</yellow>,<yellow>1</yellow>,<yellow>1</yellow>,.<yellow>3</yellow>))
<blue>print</blue>(e.model)
origin = <olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>, <olive>color</olive>=color.orange, <olive>scale</olive>=(.<yellow>0</yellow><yellow>5</yellow>, .<yellow>0</yellow><yellow>5</yellow>))
ed = EditorCamera(rotation_speed = <yellow>2</yellow><yellow>0</yellow><yellow>0</yellow>, panning_speed=<yellow>2</yellow><yellow>0</yellow><yellow>0</yellow>)
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Plane">
        <h1>Plane<a style="color: gray; font-weight:normal;" href="#Mesh">(Mesh)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/models/procedural/plane.py"><gray>ursina/models/procedural/plane</gray></a><br><br>
        <div class="params">Plane(subdivisions=(1,1), mode='triangle', **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.vertices, self.triangles<gray> = list(), list()</gray></td><td></td>
            </tr>
            <tr>
                <td>.uvs<gray> = list()</gray></td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Plane_example)">copy</button><p id="Plane_example">app = Ursina()

front =  <olive>Entity</olive>(<olive>model</olive>=<purple><b>Plane</b></purple>(subdivisions=(<yellow>3</yellow>,<yellow>6</yellow>)), <olive>texture</olive>=<green>'brick'</green>, <olive>rotation_x</olive>=-<yellow>9</yellow><yellow>0</yellow>)

_ed = EditorCamera()
<olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.green, <olive>scale</olive>=.<yellow>0</yellow><yellow>5</yellow>)
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Grid">
        <h1>Grid<a style="color: gray; font-weight:normal;" href="#Mesh">(Mesh)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/models/procedural/grid.py"><gray>ursina/models/procedural/grid</gray></a><br><br>
        <div class="params">Grid(width, height, mode='line', thickness=1, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.width<gray> = width</gray></td><td></td>
            </tr>
            <tr>
                <td>.height<gray> = height</gray></td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Grid_example)">copy</button><p id="Grid_example">app = Ursina()
<olive>Entity</olive>(<olive>model</olive>=<purple><b>Grid</b></purple>(<yellow>2</yellow>, <yellow>6</yellow>))
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Cone">
        <h1>Cone<a style="color: gray; font-weight:normal;" href="#Mesh">(Mesh)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/models/procedural/cone.py"><gray>ursina/models/procedural/cone</gray></a><br><br>
        <div class="params">Cone(resolution=4, radius=.5, height=1, add_bottom=True, mode='triangle', **kwargs)</div><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Cone_example)">copy</button><p id="Cone_example"><purple>from</purple> ursina <purple>import</purple> Ursina, <olive>Entity</olive>, color, EditorCamera
app = Ursina()
e = <olive>Entity</olive>(<olive>model</olive>=<purple><b>Cone</b></purple>(<yellow>3</yellow>), <olive>texture</olive>=<green>'brick'</green>)


origin = <olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>, <olive>color</olive>=color.orange, <olive>scale</olive>=(.<yellow>0</yellow><yellow>5</yellow>, .<yellow>0</yellow><yellow>5</yellow>))
ed = EditorCamera()
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Cylinder">
        <h1>Cylinder<a style="color: gray; font-weight:normal;" href="#Pipe">(Pipe)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/models/procedural/cylinder.py"><gray>ursina/models/procedural/cylinder</gray></a><br><br>
        <div class="params">Cylinder(resolution=8, radius=.5, start=0, height=1, direction=(0,1,0), mode='triangle', **kwargs)</div><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Cylinder_example)">copy</button><p id="Cylinder_example">app = Ursina()
<olive>Entity</olive>(<olive>model</olive>=<purple><b>Cylinder</b></purple>(<yellow>6</yellow>, start=-.<yellow>5</yellow>), <olive>color</olive>=color.hsv(<yellow>6</yellow><yellow>0</yellow>,<yellow>1</yellow>,<yellow>1</yellow>,.<yellow>3</yellow>))
origin = <olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>, <olive>color</olive>=color.orange, <olive>scale</olive>=(<yellow>5</yellow>, .<yellow>0</yellow><yellow>5</yellow>))
ed = EditorCamera(rotation_speed = <yellow>2</yellow><yellow>0</yellow><yellow>0</yellow>, panning_speed=<yellow>2</yellow><yellow>0</yellow><yellow>0</yellow>)
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Pipe">
        <h1>Pipe<a style="color: gray; font-weight:normal;" href="#Mesh">(Mesh)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/models/procedural/pipe.py"><gray>ursina/models/procedural/pipe</gray></a><br><br>
        <div class="params">Pipe(base_shape=Quad, origin=(0,0), path=((0,0,0),(0,1,0)), thicknesses=((1,1),), color_gradient=None, look_at=True, cap_ends=True, mode='triangle', **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.base_shape<gray> = base_shape</gray></td><td></td>
            </tr>
            <tr>
                <td>.origin<gray> = origin</gray></td><td></td>
            </tr>
            <tr>
                <td>.path<gray> = path</gray></td><td></td>
            </tr>
            <tr>
                <td>.thicknesses<gray> = thicknesses</gray></td><td></td>
            </tr>
            <tr>
                <td>.look_at<gray> = look_at</gray></td><td></td>
            </tr>
            <tr>
                <td>.cap_ends<gray> = cap_ends</gray></td><td></td>
            </tr>
            <tr>
                <td>.mode<gray> = mode</gray></td><td></td>
            </tr>
            <tr>
                <td>.color_gradient<gray> = color_gradient</gray></td><td></td>
            </tr>
            <tr>
                <td>.prev<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.curr<gray> = None</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;generate()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Pipe_example)">copy</button><p id="Pipe_example">app = Ursina()
path = [e*<yellow>5</yellow> <purple>for</purple> e in Circle().vertices]

path.append(path[<yellow>0</yellow>])
e = <olive>Entity</olive>(<olive>model</olive>=<purple><b>Pipe</b></purple>(path=path, cap_ends=False))
<blue>print</blue>(len(e.model.vertices), len(e.model.colors))

EditorCamera()
origin = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.magenta)
origin.scale *= .<yellow>2</yellow><yellow>5</yellow>
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Terrain">
        <h1>Terrain<a style="color: gray; font-weight:normal;" href="#Mesh">(Mesh)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/models/procedural/terrain.py"><gray>ursina/models/procedural/terrain</gray></a><br><br>
        <div class="params">Terrain(heightmap='', height_values=None, gradient=None, skip=1, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.width<gray> = len(self.height_values)</gray></td><td></td>
            </tr>
            <tr>
                <td>.depth<gray> = len(self.height_values[0])</gray></td><td></td>
            </tr>
            <tr>
                <td>.aspect_ratio<gray> = self.width / self.depth</gray></td><td></td>
            </tr>
            <tr>
                <td>.gradient<gray> = gradient</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;generate()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Terrain_example)">copy</button><p id="Terrain_example">app = Ursina()
<green><green><green>''</green></green>'Terrain using an RGB texture as input<green><green>''</green></green>'</green>
terrain_from_heightmap_texture = <olive>Entity</olive>(<olive>model</olive>=<purple><b>Terrain</b></purple>(<green>'heightmap_1'</green>, skip=<yellow>8</yellow>), <olive>scale</olive>=(<yellow>4</yellow><yellow>0</yellow>,<yellow>5</yellow>,<yellow>2</yellow><yellow>0</yellow>), <olive>texture</olive>=<green>'heightmap_1'</green>)

<green><green>''</green>'
I'm just getting the height values from the previous terrain as an example, but you can provide your own.
It should be a list of lists, where each value is between 0 and 255.
<green>''</green>'</green>
hv = terrain_from_heightmap_texture.model.height_values.tolist()
terrain_from_list = <olive>Entity</olive>(<olive>model</olive>=<purple><b>Terrain</b></purple>(height_values=hv), <olive>scale</olive>=(<yellow>4</yellow><yellow>0</yellow>,<yellow>5</yellow>,<yellow>2</yellow><yellow>0</yellow>), <olive>texture</olive>=<green>'heightmap_1'</green>, x=<yellow>4</yellow><yellow>0</yellow>)
terrain_bounds = <olive>Entity</olive>(<olive>model</olive>=<green>'wireframe_cube'</green>, origin_<olive>y</olive>=-.<yellow>5</yellow>, <olive>scale</olive>=(<yellow>4</yellow><yellow>0</yellow>,<yellow>5</yellow>,<yellow>2</yellow><yellow>0</yellow>), <olive>color</olive>=color.lime)

<purple>def</purple> input(key):
    if key == <green>'space'</green>:  <gray># randomize the terrain</gray>
        terrain_from_list.model.height_values = [[random.uniform(<yellow>0</yellow>,<yellow>2</yellow><yellow>5</yellow><yellow>5</yellow>) <purple>for</purple> a in column] <purple>for</purple> column in terrain_from_list.model.height_values]
        terrain_from_list.model.generate()

EditorCamera(<olive>rotation_x</olive>=<yellow>9</yellow><yellow>0</yellow>)
camera.orthographic = True
Sky()
player = <olive>Entity</olive>(<olive>model</olive>=<green>'sphere'</green>, <olive>color</olive>=color.azure, <olive>scale</olive>=.<yellow>2</yellow>, origin_<olive>y</olive>=-.<yellow>5</yellow>)

<purple>def</purple> update():
    direction = Vec3(held_keys[<green>'d'</green>] - held_keys[<green>'a'</green>], <yellow>0</yellow>, held_keys[<green>'w'</green>] - held_keys[<green>'s'</green>]).normalized()
    player.position += direction * time.dt * <yellow>8</yellow>
    y = terraincast(player.world_position, terrain_from_list, terrain_from_list.model.height_values)
    <purple>if</purple> y is <purple>not</purple> None:
        player.y = y





app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="input_handler">
        <h1>input_handler</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/input_handler.py"><gray>ursina/input_handler</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>.held_keys<gray> = defaultdict(lambda: 0)</gray></td><td></td>
            </tr>
            <tr>
                <td>.rebinds<gray> = dict()</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;bind(<gray>original_key, alternative_key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;unbind(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;rebind(<gray>to_key, from_key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;get_combined_key(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(input_handler_example)">copy</button><p id="input_handler_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, input_handler

app = Ursina(borderless=False)
input_handler.bind(<green><green>'z'</green></green>, <green><green>'w'</green></green>)  <gray># <green><green>'z'</green></green>-key will now be registered as <green><green>'w'</green></green>-key</gray>
input_handler.bind(<green><green>'left mouse down'</green></green>, <green><green>'attack'</green></green>)  <gray># <green><green>'left mouse down'</green></green>-key will now send <green><green>'attack'</green></green>to input functions</gray>
input_handler.bind(<green><green>'gamepad b'</green></green>, <green><green>'attack'</green></green>)  <gray># <green><green>'gamepad b'</green></green>-key will now be registered as <green><green>'attack'</green></green>-key</gray>


<purple>def</purple> input(key):
    <blue>print</blue>(<green>'got key:'</green>, key)
    <purple>if</purple> key == <green>'attack'</green>:
        destroy(<olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.blue), dela<olive>y</olive>=.<yellow>2</yellow>)






app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="mesh_importer">
        <h1>mesh_importer</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/mesh_importer.py"><gray>ursina/mesh_importer</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>.blender_scenes<gray> = dict()</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;load_model(<gray>name, folder=Func(getattr, application, 'asset_folder'), file_types=('.bam', '.ursinamesh', '.obj', '.glb', '.gltf', '.blend'), use_deepcopy=False, gltf_no_srgb=Func(getattr, application, 'gltf_no_srgb')</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;load_blender_scene(<gray>name, path=Func(getattr, application, 'asset_folder'), reload=False, skip_hidden=True, models_only=False, uvs=True, vertex_colors=True, normals=True, triangulate=True, decimals=4</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;get_blender(<gray>blend_file</gray>)</td> <td><span>try to get a matching blender version in case we have multiple blender version installed</span></td>
            </tr>
            <tr>
                <td> &nbsp;blend_to_obj(<gray>blend_file:Path, out_folder=Func(getattr, application, 'compressed_models_folder'), export_mtl=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;obj_to_ursinamesh(<gray>folder=Func(getattr, application, 'compressed_models_folder'), out_folder=Func(getattr, application, 'compressed_models_folder'), name='*', return_mesh=True, save_to_file=False, delete_obj=False</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;blend_to_obj_fast(<gray>model_name=None, write_to_disk=False</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;ursina_mesh_to_obj(<gray>mesh, name='', out_path=Func(getattr, application, 'compressed_models_folder'), max_decimals=5, flip_faces=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;compress_internal()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(mesh_importer_example)">copy</button><p id="mesh_importer_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, <olive>Entity</olive>, EditorCamera, Sky
app = Ursina()
m = obj_to_ursinamesh(folder=application.asset_folder.parent / <green>'samples'</green>, name=<green>'procedural_rock_0'</green>, save_to_file=False, delete_obj=False)
<blue>print</blue>(m.serialize())






EditorCamera()
Sky(<olive>texture</olive>=<green>'sky_sunset'</green>)


app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="texture_importer">
        <h1>texture_importer</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/texture_importer.py"><gray>ursina/texture_importer</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>.file_types<gray> = ('.tif', '.jpg', '.jpeg', '.png', '.gif')</gray></td><td></td>
            </tr>
            <tr>
                <td>.folders<gray> = [ </gray></td><td><span>folder search order</span></td>
            </tr>
            <tr>
                <td>.textureless<gray> = False</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;load_texture(<gray>name, path=None, use_cache=True, filtering='default'</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;compress_textures(<gray>name=''</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(texture_importer_example)">copy</button><p id="texture_importer_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()
<olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>, <olive>texture</olive>=<green>'white_cube'</green>)
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="string_utilities">
        <h1>string_utilities</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/string_utilities.py"><gray>ursina/string_utilities</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;camel_to_snake(<gray>value</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;snake_to_camel(<gray>value</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;multireplace(<gray>string, replacements, ignore_case=False</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;printvar(<gray>var</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;print_info(<gray>str, *args</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;print_warning(<gray>str, *args</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(string_utilities_example)">copy</button><p id="string_utilities_example"><blue>print</blue>(camel_to_snake(<green>'CamelToSnake'</green>))
<blue>print</blue>(snake_to_camel(<green>'snake_to_camel'</green>))
printvar(<green>'test'</green>)</p>
</div>

</div>
<br>
    <div class="class_box" id="Animation">
        <h1>Animation<a style="color: gray; font-weight:normal;" href="#Sprite">(Sprite)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/animation.py"><gray>ursina/prefabs/animation</gray></a><br><br>
        <div class="params">Animation(name, fps=12, loop=True, autoplay=True, frame_times=None, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.sequence<gray> = Sequence(loop=loop, auto_destroy=False)</gray></td><td></td>
            </tr>
            <tr>
                <td>.frame_times<gray> = frame_times</gray></td><td></td>
            </tr>
            <tr>
                <td>.is_playing<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.autoplay<gray> = autoplay</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.duration</td><td><span>get the duration of the animation. you can't set it. to do so, change the fps instead.</span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;start()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;pause()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;resume()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;finish()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Animation_example)">copy</button><p id="Animation_example">app = Ursina()

    <green><green>''</green>'
    Loads an image sequence as a frame animation.
    Consider using SpriteSheetAnimation instead if possible.
    So if you have some frames named image_000.png, image_001.png, image_002.png and so on,
    you can load it like this: <b>Animation</b>(<green>'image'</green>)

    You can also load a .gif by including the file type: <b>Animation</b>(<green>'image.gif'</green>)
    <green>''</green>'</green>

    a = <purple><b>Animation</b></purple>(<green>'ursina_wink'</green>)

    app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="FrameAnimation3d">
        <h1>FrameAnimation3d<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/frame_animation_3d.py"><gray>ursina/prefabs/frame_animation_3d</gray></a><br><br>
        <div class="params">FrameAnimation3d(name, fps=12, loop=True, autoplay=True, frame_times=None, auto_destroy=False, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.play<gray> = self.start</gray></td><td></td>
            </tr>
            <tr>
                <td>.frames<gray> = [Entity(parent=self, model=e.stem, enabled=False, add_to_scene_entities=False) for e in model_names]</gray></td><td></td>
            </tr>
            <tr>
                <td>.sequence<gray> = Sequence(loop=loop, auto_destroy=auto_destroy)</gray></td><td></td>
            </tr>
            <tr>
                <td>.autoplay<gray> = autoplay</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.duration</td><td><span></span></td>
            </tr>
            <tr>
                <td>.current_frame</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;start()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;pause()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;resume()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;finish()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_destroy()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(FrameAnimation3d_example)">copy</button><p id="FrameAnimation3d_example">application.asset_folder = application.asset_folder.parent.parent / <green>'samples'</green>
app = Ursina()

<green><green>''</green>'
Loads an obj sequence as a frame animation.
So if you have some frames named run_cycle_000.obj, run_cycle_001.obj, run_cycle_002.obj and so on,
you can load it like this: FrameAnimation3d(<green>'run_cycle_'</green>)
<green>''</green>'</green>

FrameAnimation<yellow>3</yellow>d(<green>'blob_animation_'</green>)</p>
</div>

</div>
<br>
    <div class="class_box" id="SpriteSheetAnimation">
        <h1>SpriteSheetAnimation<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/sprite_sheet_animation.py"><gray>ursina/prefabs/sprite_sheet_animation</gray></a><br><br>
        <div class="params">SpriteSheetAnimation(texture, animations, tileset_size=[4,1], fps=12, model='quad', autoplay=True, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.animations<gray> = animations </gray></td><td><span>should be a dict</span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;play_animation(<gray>animation_name</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(SpriteSheetAnimation_example)">copy</button><p id="SpriteSheetAnimation_example"><green><green>''</green>'
Sprite sheet coordinate system:
(0,3) (1,3) (2,3) (3,3)
(0,2) (1,2) (2,2) (3,2)
(0,1) (1,1) (2,1) (3,1)
(0,0) (1,0) (2,0) (3,0)
<green>''</green>'</green>
<purple>from</purple> ursina <purple>import</purple> Ursina
app = Ursina()
player_graphics = <purple><b>SpriteSheetAnimation</b></purple>(<green>'sprite_sheet'</green>, tileset_size=(<yellow>4</yellow>,<yellow>4</yellow>), fps=<yellow>6</yellow>, animations={
    <green>'idle'</green> : ((0,0), (0,0)),        <gray># makes an animation from (0,0) to (0,0), a single frame</gray>
    <green>'walk_up'</green> : ((0,0), (3,0)),     <gray># makes an animation from (0,0) to (3,0), the bottom row</gray>
    <green>'walk_right'</green> : ((<yellow>0</yellow>,<yellow>1</yellow>), (<yellow>3</yellow>,<yellow>1</yellow>)),
    <green>'walk_left'</green> : ((<yellow>0</yellow>,<yellow>2</yellow>), (<yellow>3</yellow>,<yellow>2</yellow>)),
    <green>'walk_down'</green> : ((<yellow>0</yellow>,<yellow>3</yellow>), (<yellow>3</yellow>,<yellow>3</yellow>)),
    }
    )
<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'w'</green>:
        player_graphics.play_animation(<green>'walk_up'</green>)
    <purple>elif</purple> key == <green>'s'</green>:
        player_graphics.play_animation(<green>'walk_down'</green>)
    <purple>elif</purple> key == <green>'d'</green>:
        player_graphics.play_animation(<green>'walk_right'</green>)
    <purple>elif</purple> key == <green>'a'</green>:
        player_graphics.play_animation(<green>'walk_left'</green>)



<olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>, <olive>texture</olive>=<green>'sprite_sheet'</green>, x=-<yellow>1</yellow>)
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Animator">
        <h1>Animator</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/animator.py"><gray>ursina/prefabs/animator</gray></a><br><br>
        <div class="params">Animator(animations=None, start_state='', pause_disabled=True)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.animations<gray> = animations    </gray></td><td><span>dict</span></td>
            </tr>
            <tr>
                <td>.pause_disabled<gray> = pause_disabled</gray></td><td></td>
            </tr>
            <tr>
                <td>.start_state<gray> = start_state</gray></td><td></td>
            </tr>
            <tr>
                <td>.state<gray> = start_state</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.state</td><td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Animator_example)">copy</button><p id="Animator_example">app = Ursina()
anim = Animation(<green>'ursina_wink'</green>, loop=True, autopla<olive>y</olive>=False)
a = <purple><b>Animator</b></purple>(
    animations = {
        <green>'lol'</green> : <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.red),
        <green>'yo'</green> : <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.green, x=<yellow>1</yellow>),
        <green>'help'</green> : anim,
    }
)
a.state = <green>'yo'</green>

Text(<green>'press &ltred&gt1&ltdefault&gt, &ltgreen&gt2&ltdefault&gt or &ltviolet&gt3&ltdefault&gt to toggle different animator states'</green>, <olive>origin</olive>=(<yellow>0</yellow>,-.<yellow>5</yellow>), <olive>y</olive>=-.<yellow>4</yellow>)

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'1'</green>:
        a.state = <green>'lol'</green>
    <purple>if</purple> key == <green>'2'</green>:
        a.state = <green>'yo'</green>
    <purple>if</purple> key == <green>'3'</green>:
        a.state = <green>'help'</green>
        <blue>print</blue>(anim.enabled)

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="TrailRenderer">
        <h1>TrailRenderer<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/trail_renderer.py"><gray>ursina/prefabs/trail_renderer</gray></a><br><br>
        <div class="params">TrailRenderer(size=[1,.01], segments=8, min_spacing=.05, fade_speed=0, color_gradient=[color.white, color.clear], **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.renderer<gray> = Entity(
        model = Pipe(
            base_shape = Quad(segments=0, scale=size),
            path=[Vec3(0,0,i) for i in range(2)],
            color_gradient=color_gradient,
            static=False,
            cap_ends=False,
        ),</gray></td><td></td>
            </tr>
            <tr>
                <td>.segments<gray> = segments</gray></td><td></td>
            </tr>
            <tr>
                <td>.update_step<gray> = .05</gray></td><td></td>
            </tr>
            <tr>
                <td>.min_spacing<gray> = min_spacing</gray></td><td></td>
            </tr>
            <tr>
                <td>.fade_speed<gray> = fade_speed</gray></td><td></td>
            </tr>
            <tr>
                <td>.on_enable<gray> = self.renderer.enable</gray></td><td></td>
            </tr>
            <tr>
                <td>.on_disable<gray> = self.renderer.disable</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_destroy()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(TrailRenderer_example)">copy</button><p id="TrailRenderer_example">app = Ursina(vsync=False)
window.color = color.black
mouse.visible = False
player = <olive>Entity</olive>(<olive>z</olive>=<yellow>1</yellow>)
player.graphics = <olive>Entity</olive>(<olive>parent</olive>=player, <olive>scale</olive>=.<yellow>1</yellow>, <olive>model</olive>=<green>'circle'</green>)

pivot = <olive>Entity</olive>()

trail_renderers = []
<purple>for</purple> i in <blue>range</blue>(<yellow>1</yellow>):
    tr = <purple><b>TrailRenderer</b></purple>(size=[<yellow>1</yellow>,<yellow>1</yellow>], segments=<yellow>8</yellow>, min_spacing=.<yellow>0</yellow><yellow>5</yellow>, fade_speed=<yellow>0</yellow>, <olive>parent</olive>=player, color_gradient=[color.magenta, color.cyan.tint(-.<yellow>5</yellow>), color.clear])
    trail_renderers.append(tr)

<purple>def</purple> update():
    player.position = lerp(player.position, mouse.position*<yellow>1</yellow><yellow>0</yellow>, time.dt*<yellow>4</yellow>)


<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'escape'</green>:
        <purple>for</purple> e in trail_renderers:
            e.enabled = <purple>not</purple> e.enabled

    <purple>if</purple> key == <green>'space'</green>:
        destroy(pivot)

EditorCamera()
<olive>Entity</olive>(<olive>model</olive>=Grid(<yellow>8</yellow>,<yellow>8</yellow>), <olive>rotation_x</olive>=<yellow>9</yellow><yellow>0</yellow>, <olive>color</olive>=color.gray, <olive>y</olive>=-<yellow>3</yellow>, <olive>scale</olive>=<yellow>8</yellow>)
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="curve">
        <h1>curve</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/curve.py"><gray>ursina/curve</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;linear(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_sine(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;out_sine(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_out_sine(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_quad(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;out_quad(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_out_quad(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_cubic(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;out_cubic(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_out_cubic(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_quart(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;out_quart(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_out_quart(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_quint(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;out_quint(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_out_quint(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_expo(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;out_expo(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_out_expo(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_circ(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;out_circ(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_out_circ(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_back(<gray>t, magnitude=1.70158</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;out_back(<gray>t, magnitude=1.70158</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_out_back(<gray>t, magnitude=1.70158</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_elastic(<gray>t, magnitude=.7</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;out_elastic(<gray>t, magnitude=.7</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_out_elastic(<gray>t, magnitude=0.65</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;out_bounce(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_bounce(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;in_out_bounce(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;zero(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;one(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;combine(<gray>curve_a, curve_b, split_at</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;reverse(<gray>curve_function</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;{e}_boomerang(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(curve_example)">copy</button><p id="curve_example"><green><green><green>''</green></green>'Draws a sheet with every curve and its name<green><green>''</green></green>'</green>
<purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, camera, window, curve, <olive>Entity</olive>, Mesh, Text, color

app = Ursina()
camera.orthographic = True
camera.fov = <yellow>1</yellow><yellow>6</yellow>
camera.position = (<yellow>9</yellow>, <yellow>6</yellow>)
window.color = color.black

<purple>def</purple> render_<purple><b>curve</b></purple>(curve_function, name):
    curve_renderer = <olive>Entity</olive>(<olive>model</olive>=Mesh(<olive>vertices</olive>=[Vec3(i / <yellow>3</yellow><yellow>1</yellow>, curve_function(i / <yellow>3</yellow><yellow>1</yellow>), <yellow>0</yellow>) <purple>for</purple> i in <blue>range</blue>(<yellow>3</yellow><yellow>2</yellow>)], <olive>mode</olive>=<green>'line'</green>, <olive>thickness</olive>=<yellow>2</yellow>), <olive>color</olive>=color.light_gray)
    label = Text(<olive>parent</olive>=curve_renderer, <olive>text</olive>=name, <olive>scale</olive>=<yellow>8</yellow>, <olive>color</olive>=color.gray, <olive>y</olive>=-.<yellow>1</yellow>)
    return curve_renderer




c = CubicBezier(<yellow>0</yellow>, .<yellow>5</yellow>, <yellow>1</yellow>, .<yellow>5</yellow>)
<blue>print</blue>(<green>'-----------'</green>, c.calculate(.<yellow>2</yellow><yellow>3</yellow>))

window.exit_button.visible = False
window.fps_counter.enabled = False

custom_curve = combine(linear, reverse(in_expo), .<yellow>2</yellow><yellow>5</yellow>)
render_<purple><b>curve</b></purple>(custom_curve, <green>'custom_curve'</green>)
EditorCamera()
app.run()
<green><green>''</green>'
These are used by Entity when animating, like this:

e = Entity()
e.animate_y(1, curve=curve.in_expo)

e2 = Entity(x=1.5)
e2.animate_y(1, curve=curve.CubicBezier(0,.7,1,.3))
<green>''</green>'</green></p>
</div>

</div>
<br>
    <div class="class_box" id="ursinamath">
        <h1>ursinamath</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursinamath.py"><gray>ursinamath</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;distance(<gray>a, b</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;distance_2d(<gray>a, b</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;distance_xz(<gray>a, b</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;lerp(<gray>a, b, t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;inverselerp(<gray>a, b, t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;lerp_angle(<gray>start_angle, end_angle, t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;slerp(<gray>q1, q2, t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;clamp(<gray>value, floor, ceiling</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;round_to_closest(<gray>value, step=0</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;rotate_around_point_2d(<gray>point, origin, deg</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;world_position_to_screen_position(<gray>point): # get screen position(ui space</gray>)</td> <td><span>get screen position(ui space) from world space.</span></td>
            </tr>
            <tr>
                <td> &nbsp;sum(<gray>l</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;make_gradient(<gray>index_color_dict</gray>)</td> <td><span>returns a list of 256 colors</span></td>
            </tr>
            <tr>
                <td> &nbsp;sample_gradient(<gray>list_of_values, t):     # distribute list_of_values equally on a line and get the interpolated value at t (0-1</gray>)</td> <td><span>distribute list_of_values equally on a line and get the interpolated value at t (0-1).</span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(ursinamath_example)">copy</button><p id="ursinamath_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()
e<yellow>1</yellow> = <olive>Entity</olive>(position = (<yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>))
e<yellow>2</yellow> = <olive>Entity</olive>(position = (<yellow>0</yellow>,<yellow>1</yellow>,<yellow>1</yellow>))
distance(e<yellow>1</yellow>, e<yellow>2</yellow>)
distance_xz(e<yellow>1</yellow>, e<yellow>2</yellow>.position)

between_color = lerp(color.lime, color.magenta, .<yellow>5</yellow>)
<blue>print</blue>(between_color)
<blue>print</blue>(lerp((<yellow>0</yellow>,<yellow>0</yellow>), (<yellow>0</yellow>,<yellow>1</yellow>), .<yellow>5</yellow>))
<blue>print</blue>(lerp(Vec2(<yellow>0</yellow>,<yellow>0</yellow>), Vec2(<yellow>0</yellow>,<yellow>1</yellow>), .<yellow>5</yellow>))
<blue>print</blue>(lerp([<yellow>0</yellow>,<yellow>0</yellow>], [<yellow>0</yellow>,<yellow>1</yellow>], .<yellow>5</yellow>))

<blue>print</blue>(round(Vec3(.<yellow>3</yellow><yellow>8</yellow>, .<yellow>1</yellow><yellow>3</yellow><yellow>5</yellow><yellow>1</yellow>, <yellow>3</yellow><yellow>5</yellow><yellow>3</yellow>.<yellow>2</yellow><yellow>6</yellow>), <yellow>2</yellow>))

p = (<yellow>1</yellow>,<yellow>0</yellow>)
<blue>print</blue>(p, <green>'rotated -&gt'</green>, rotate_around_point_<yellow>2</yellow>d(p, (<yellow>0</yellow>,<yellow>0</yellow>), <yellow>9</yellow><yellow>0</yellow>))

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Vec2">
        <h1>Vec2<a style="color: gray; font-weight:normal;" href="#PandaVec2">(PandaVec2)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/vec2.py"><gray>ursina/vec2</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.x</td><td><span></span></td>
            </tr>
            <tr>
                <td>.y</td><td><span></span></td>
            </tr>
            <tr>
                <td>.X</td><td><span></span></td>
            </tr>
            <tr>
                <td>.Y</td><td><span></span></td>
            </tr>
            <tr>
                <td>.yx</td><td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Vec2_example)">copy</button><p id="Vec2_example">a = <purple><b>Vec2</b></purple>(<yellow>1</yellow>,<yellow>1</yellow>)
<blue>print</blue>(a)
<blue>print</blue>(round(a))</p>
</div>

</div>
<br>
    <div class="class_box" id="Vec3">
        <h1>Vec3<a style="color: gray; font-weight:normal;" href="#PandaVec3">(PandaVec3)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/vec3.py"><gray>ursina/vec3</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.x</td><td><span></span></td>
            </tr>
            <tr>
                <td>.y</td><td><span></span></td>
            </tr>
            <tr>
                <td>.z</td><td><span></span></td>
            </tr>
            <tr>
                <td>.xy</td><td><span></span></td>
            </tr>
            <tr>
                <td>.yx</td><td><span></span></td>
            </tr>
            <tr>
                <td>.xz</td><td><span></span></td>
            </tr>
            <tr>
                <td>.yz</td><td><span></span></td>
            </tr>
            <tr>
                <td>.X</td><td><span></span></td>
            </tr>
            <tr>
                <td>.Y</td><td><span></span></td>
            </tr>
            <tr>
                <td>.Z</td><td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Vec3_example)">copy</button><p id="Vec3_example">a = <purple><b>Vec3</b></purple>(<yellow>1</yellow>,<yellow>0</yellow>,<yellow>0</yellow>) * <yellow>2</yellow>
a = <purple><b>Vec3</b></purple>(<yellow>1</yellow>,<yellow>0</yellow>,<yellow>1</yellow>) * <purple><b>Vec3</b></purple>(<yellow>2</yellow>,<yellow>1</yellow>,<yellow>2</yellow>)
b = <purple><b>Vec3</b></purple>(<yellow>1</yellow>.<yellow>2</yellow><yellow>5</yellow><yellow>2</yellow><yellow>3</yellow><yellow>5</yellow><yellow>2</yellow><yellow>3</yellow><yellow>2</yellow><yellow>4</yellow>,<yellow>0</yellow>,<yellow>1</yellow>)
b += <purple><b>Vec3</b></purple>(<yellow>0</yellow>,<yellow>1</yellow>)</p>
</div>

</div>
<br>
    <div class="class_box" id="Vec4">
        <h1>Vec4<a style="color: gray; font-weight:normal;" href="#PandaVec4">(PandaVec4)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/vec4.py"><gray>ursina/vec4</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Vec4_example)">copy</button><p id="Vec4_example">a = Vec<yellow>4</yellow>(<yellow>1</yellow>,<yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>) * <yellow>2</yellow>
a = Vec<yellow>4</yellow>(<yellow>1</yellow>,<yellow>0</yellow>,<yellow>1</yellow>,<yellow>1</yellow>) * Vec<yellow>4</yellow>(<yellow>2</yellow>,<yellow>1</yellow>,<yellow>2</yellow>,<yellow>3</yellow>)
b = Vec<yellow>4</yellow>(<yellow>1</yellow>.<yellow>2</yellow><yellow>5</yellow><yellow>2</yellow><yellow>3</yellow><yellow>5</yellow><yellow>2</yellow><yellow>3</yellow><yellow>2</yellow><yellow>4</yellow>,<yellow>0</yellow>,<yellow>1</yellow>,.<yellow>2</yellow>)
b += Vec<yellow>4</yellow>(<yellow>0</yellow>,<yellow>1</yellow>)</p>
</div>

</div>
<br>
    <div class="class_box" id="CubicBezier">
        <h1>CubicBezier</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/curve.py"><gray>ursina/curve</gray></a><br><br>
        <div class="params">CubicBezier(a, b, c, d)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.a<gray> = a</gray></td><td></td>
            </tr>
            <tr>
                <td>.b<gray> = b</gray></td><td></td>
            </tr>
            <tr>
                <td>.c<gray> = c</gray></td><td></td>
            </tr>
            <tr>
                <td>.d<gray> = d</gray></td><td></td>
            </tr>
            <tr>
                <td>.cx<gray> = 3.0 * a</gray></td><td></td>
            </tr>
            <tr>
                <td>.bx<gray> = 3.0 * (c - a) - self.cx</gray></td><td></td>
            </tr>
            <tr>
                <td>.ax<gray> = 1.0 - self.cx - self.bx</gray></td><td></td>
            </tr>
            <tr>
                <td>.cy<gray> = 3.0 * b</gray></td><td></td>
            </tr>
            <tr>
                <td>.by<gray> = 3.0 * (d - b) - self.cy</gray></td><td></td>
            </tr>
            <tr>
                <td>.ay<gray> = 1.0 - self.cy - self.by</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;sample_curve_x(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;sample_curve_y(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;sample_curve_derivative_x(<gray>t</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;calculate(<gray>x, epsilon=.0001</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;solve_curve_x(<gray>t, epsilon=.0001</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(CubicBezier_example)">copy</button><p id="CubicBezier_example"><green><green><green>''</green></green>'Draws a sheet with every curve and its name<green><green>''</green></green>'</green>
<purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, camera, window, curve, <olive>Entity</olive>, Mesh, Text, color

app = Ursina()
camera.orthographic = True
camera.fov = <yellow>1</yellow><yellow>6</yellow>
camera.position = (<yellow>9</yellow>, <yellow>6</yellow>)
window.color = color.black

<purple>def</purple> render_curve(curve_function, name):
    curve_renderer = <olive>Entity</olive>(<olive>model</olive>=Mesh(<olive>vertices</olive>=[Vec3(i / <yellow>3</yellow><yellow>1</yellow>, curve_function(i / <yellow>3</yellow><yellow>1</yellow>), <yellow>0</yellow>) <purple>for</purple> i in <blue>range</blue>(<yellow>3</yellow><yellow>2</yellow>)], <olive>mode</olive>=<green>'line'</green>, <olive>thickness</olive>=<yellow>2</yellow>), <olive>color</olive>=color.light_gray)
    label = Text(<olive>parent</olive>=curve_renderer, <olive>text</olive>=name, <olive>scale</olive>=<yellow>8</yellow>, <olive>color</olive>=color.gray, <olive>y</olive>=-.<yellow>1</yellow>)
    return curve_renderer




c = <purple><b>CubicBezier</b></purple>(<yellow>0</yellow>, .<yellow>5</yellow>, <yellow>1</yellow>, .<yellow>5</yellow>)
<blue>print</blue>(<green>'-----------'</green>, c.calculate(.<yellow>2</yellow><yellow>3</yellow>))

window.exit_button.visible = False
window.fps_counter.enabled = False

custom_curve = combine(linear, reverse(in_expo), .<yellow>2</yellow><yellow>5</yellow>)
render_curve(custom_curve, <green>'custom_curve'</green>)
EditorCamera()
app.run()
<green><green>''</green>'
These are used by Entity when animating, like this:

e = Entity()
e.animate_y(1, curve=curve.in_expo)

e2 = Entity(x=1.5)
e2.animate_y(1, curve=curve.<b>CubicBezier</b>(0,.7,1,.3))
<green>''</green>'</green></p>
</div>

</div>
<br>
    <div class="class_box" id="ursinastuff">
        <h1>ursinastuff</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursinastuff.py"><gray>ursinastuff</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;invoke(<gray>function, *args, **kwargs</gray>)</td> <td><span>reserved keywords: 'delay', 'unscaled'</span></td>
            </tr>
            <tr>
                <td> &nbsp;after(<gray>delay, unscaled=True</gray>)</td> <td><span>function for @after decorator. Use the docrator, not this.</span></td>
            </tr>
            <tr>
                <td> &nbsp;reset_cooldown()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;wrapper(<gray>*args, **kwargs</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;destroy(<gray>entity, delay=0</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;chunk_list(<gray>target_list, chunk_size</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;flatten_list(<gray>target_list</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;flatten_completely(<gray>target_list</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;enumerate_2d(<gray>target_2d_list):    # usage: for (x, y), value in enumerate_2d(my_2d_list</gray>)</td> <td><span>usage: for (x, y), value in enumerate_2d(my_2d_list)</span></td>
            </tr>
            <tr>
                <td> &nbsp;enumerate_3d(<gray>target_3d_list):   # usage: for (x, y, z), value in enumerate_3d(my_3d_list</gray>)</td> <td><span>usage: for (x, y, z), value in enumerate_3d(my_3d_list)</span></td>
            </tr>
            <tr>
                <td> &nbsp;rotate_2d_list(<gray>target_2d_list</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;list_2d_to_string(<gray>target_2d_list, characters='.#'</gray>)</td> <td><span>'):</span></td>
            </tr>
            <tr>
                <td> &nbsp;size_list()</td> <td><span>return a list of current python objects sorted by size</span></td>
            </tr>
            <tr>
                <td> &nbsp;find_sequence(<gray>name, file_types, folders</gray>)</td> <td><span>find frame_0, frame_1, frame_2 and so on</span></td>
            </tr>
            <tr>
                <td> &nbsp;import_all_classes(<gray>path=application.asset_folder, debug=False</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;print_on_screen(<gray>text, position=(0,0), origin=(-.5,.5), scale=1, duration=1</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(ursinastuff_example)">copy</button><p id="ursinastuff_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()


list_<yellow>2</yellow>d = [
    [<yellow>1</yellow>,<yellow>0</yellow>,<yellow>0</yellow>,<yellow>1</yellow>, <yellow>0</yellow>, <yellow>1</yellow>,<yellow>1</yellow>,<yellow>1</yellow>,<yellow>0</yellow>, <yellow>0</yellow>, <yellow>1</yellow>,<yellow>1</yellow>,<yellow>1</yellow>,<yellow>1</yellow>, <yellow>0</yellow>, <yellow>0</yellow>,<yellow>1</yellow>,<yellow>0</yellow>,<yellow>0</yellow>],
    [<yellow>1</yellow>,<yellow>0</yellow>,<yellow>0</yellow>,<yellow>1</yellow>, <yellow>0</yellow>, <yellow>1</yellow>,<yellow>0</yellow>,<yellow>0</yellow>,<yellow>1</yellow>, <yellow>0</yellow>, <yellow>1</yellow>,<yellow>1</yellow>,<yellow>1</yellow>,<yellow>0</yellow>, <yellow>0</yellow>, <yellow>0</yellow>,<yellow>1</yellow>,<yellow>0</yellow>,<yellow>0</yellow>],
    [<yellow>1</yellow>,<yellow>0</yellow>,<yellow>0</yellow>,<yellow>1</yellow>, <yellow>0</yellow>, <yellow>1</yellow>,<yellow>1</yellow>,<yellow>1</yellow>,<yellow>0</yellow>, <yellow>0</yellow>, <yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>,<yellow>1</yellow>, <yellow>0</yellow>, <yellow>0</yellow>,<yellow>1</yellow>,<yellow>0</yellow>,<yellow>0</yellow>],
    [<yellow>0</yellow>,<yellow>1</yellow>,<yellow>1</yellow>,<yellow>0</yellow>, <yellow>0</yellow>, <yellow>1</yellow>,<yellow>0</yellow>,<yellow>0</yellow>,<yellow>1</yellow>, <yellow>0</yellow>, <yellow>1</yellow>,<yellow>1</yellow>,<yellow>1</yellow>,<yellow>1</yellow>, <yellow>0</yellow>, <yellow>0</yellow>,<yellow>1</yellow>,<yellow>0</yellow>,<yellow>0</yellow>],
]
<blue>print</blue>(list_<yellow>2</yellow>d_to_string(list_<yellow>2</yellow>d))


a = Audio(<green>'sine'</green>)
a.play()
destroy(a, dela<olive>y</olive>=<yellow>1</yellow>)
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Sequence">
        <h1>Sequence</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/sequence.py"><gray>ursina/sequence</gray></a><br><br>
        <div class="params">Sequence(*args, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.args<gray> = list(args)</gray></td><td></td>
            </tr>
            <tr>
                <td>.t<gray> = 0</gray></td><td></td>
            </tr>
            <tr>
                <td>.time_step<gray> = Sequence.default_time_step</gray></td><td></td>
            </tr>
            <tr>
                <td>.duration<gray> = 0</gray></td><td></td>
            </tr>
            <tr>
                <td>.funcs<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.func_call_time<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.func_finished_statuses<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.paused<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.entity<gray> = None  </gray></td><td><span>you can assign this to make the sequence pause when the entity is disabled or .ignore is True</span></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.finished</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;generate()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;append(<gray>arg, regenerate=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;extend(<gray>list</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;start()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;pause()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;resume()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;finish()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;kill()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Sequence_example)">copy</button><p id="Sequence_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, <olive>Entity</olive>
app = Ursina()
e = <olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>)
<purple>def</purple> some_func():
    <blue>print</blue>(<green>'some_func'</green>)

s = <purple><b>Sequence</b></purple>(
    some_func,
    <yellow>1</yellow>,
    Func(print, <green>'one'</green>),
    Func(e.fade_out, duration=<yellow>1</yellow>),
    Wait(<yellow>1</yellow>),
    loop=True
    )

<purple>for</purple> i in <blue>range</blue>(<yellow>8</yellow>):
    s.append(Func(print, i))
    s.append(Wait(.<yellow>2</yellow>))

<blue>print</blue>(s)

<purple>def</purple> input(key):
    actions = {<green>'s'</green> : s.start, <green>'f'</green> : s.finish, <green>'p'</green> : s.pause, <green>'r'</green> : s.resume}
    <purple>if</purple> key in actions:
        actions[key]()

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Func">
        <h1>Func</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/sequence.py"><gray>ursina/sequence</gray></a><br><br>
        <div class="params">Func(func, *args, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.func<gray> = func</gray></td><td></td>
            </tr>
            <tr>
                <td>.args<gray> = args</gray></td><td></td>
            </tr>
            <tr>
                <td>.kwargs<gray> = kwargs</gray></td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Func_example)">copy</button><p id="Func_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, <olive>Entity</olive>
app = Ursina()
e = <olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>)
<purple>def</purple> some_func():
    <blue>print</blue>(<green>'some_func'</green>)

s = Sequence(
    some_func,
    <yellow>1</yellow>,
    <purple><b>Func</b></purple>(print, <green>'one'</green>),
    <purple><b>Func</b></purple>(e.fade_out, duration=<yellow>1</yellow>),
    Wait(<yellow>1</yellow>),
    loop=True
    )

<purple>for</purple> i in <blue>range</blue>(<yellow>8</yellow>):
    s.append(<purple><b>Func</b></purple>(print, i))
    s.append(Wait(.<yellow>2</yellow>))

<blue>print</blue>(s)

<purple>def</purple> input(key):
    actions = {<green>'s'</green> : s.start, <green>'f'</green> : s.finish, <green>'p'</green> : s.pause, <green>'r'</green> : s.resume}
    <purple>if</purple> key in actions:
        actions[key]()

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Keys">
        <h1>Keys<a style="color: gray; font-weight:normal;" href="#Enum">(Enum)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/input_handler.py"><gray>ursina/input_handler</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>Keys.left_mouse_down = 'left mouse down'</td><td></td>
            </tr>
            <tr>
                <td>Keys.left_mouse_up = 'left mouse up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.middle_mouse_down = 'middle mouse down'</td><td></td>
            </tr>
            <tr>
                <td>Keys.middle_mouse_up = 'middle mouse up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.right_mouse_down = 'right mouse down'</td><td></td>
            </tr>
            <tr>
                <td>Keys.right_mouse_up = 'right mouse up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.double_click = 'double click'</td><td></td>
            </tr>
            <tr>
                <td>Keys.scroll_up = 'scroll up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.scroll_down = 'scroll down'</td><td></td>
            </tr>
            <tr>
                <td>Keys.left_arrow = 'left arrow'</td><td></td>
            </tr>
            <tr>
                <td>Keys.left_arrow_up = 'left arrow up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.up_arrow = 'up arrow'</td><td></td>
            </tr>
            <tr>
                <td>Keys.up_arrow_up = 'up arrow up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.down_arrow = 'down arrow'</td><td></td>
            </tr>
            <tr>
                <td>Keys.down_arrow_up = 'down arrow up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.right_arrow = 'right arrow'</td><td></td>
            </tr>
            <tr>
                <td>Keys.right_arrow_up = 'right arrow up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.left_control = 'left control'</td><td></td>
            </tr>
            <tr>
                <td>Keys.right_control = 'right control'</td><td></td>
            </tr>
            <tr>
                <td>Keys.left_shift = 'left shift'</td><td></td>
            </tr>
            <tr>
                <td>Keys.right_shift = 'right shift'</td><td></td>
            </tr>
            <tr>
                <td>Keys.left_alt = 'left alt'</td><td></td>
            </tr>
            <tr>
                <td>Keys.right_alt = 'right alt'</td><td></td>
            </tr>
            <tr>
                <td>Keys.left_control_up = 'left control up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.right_control_up = 'right control up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.left_shift_up = 'left shift up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.right_shift_up = 'right shift up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.left_alt_up = 'left alt up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.right_alt_up = 'right alt up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.page_down = 'page down'</td><td></td>
            </tr>
            <tr>
                <td>Keys.page_down_up = 'page down up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.page_up = 'page up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.page_up_up = 'page up up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.enter = 'enter'</td><td></td>
            </tr>
            <tr>
                <td>Keys.backspace = 'backspace'</td><td></td>
            </tr>
            <tr>
                <td>Keys.escape = 'escape'</td><td></td>
            </tr>
            <tr>
                <td>Keys.tab = 'tab'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_left_stick_x = 'gamepad left stick x'   # held_keys only</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_left_stick_y = 'gamepad left stick y'   # held_keys only</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_right_stick_x = 'gamepad right stick x'   # held_keys only</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_right_stick_y = 'gamepad right stick y'   # held_keys only</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_left_trigger = 'gamepad left trigger'   # held_keys only</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_right_trigger = 'gamepad right trigger'   # held_keys only</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_a = 'gamepad a'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_a_up = 'gamepad a up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_b = 'gamepad b'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_b_up = 'gamepad b up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_x = 'gamepad x'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_x_up = 'gamepad x up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_y = 'gamepad y'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_y_up = 'gamepad y up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_left_stick = 'gamepad left stick'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_left_stick_up = 'gamepad left stick up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_right_stick = 'gamepad right stick'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_right_stick_up = 'gamepad right stick up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_back = 'gamepad back'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_back_up = 'gamepad back up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_start = 'gamepad start'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_dpad_down = 'gamepad dpad down'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_dpad_down_up = 'gamepad dpad down up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_dpad_up = 'gamepad dpad up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_dpad_up_up = 'gamepad dpad up up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_dpad_left = 'gamepad dpad left'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_dpad_left_up = 'gamepad dpad left up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_dpad_right = 'gamepad dpad right'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_dpad_right_up = 'gamepad dpad right up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_left_shoulder = 'gamepad left shoulder'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_left_shoulder_up = 'gamepad left shoulder up'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_right_shoulder = 'gamepad right shoulder'</td><td></td>
            </tr>
            <tr>
                <td>Keys.gamepad_right_shoulder_up = 'gamepad right shoulder up'</td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;bind(<gray>original_key, alternative_key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;unbind(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;rebind(<gray>to_key, from_key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;get_combined_key(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Keys_example)">copy</button><p id="Keys_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, input_handler

app = Ursina(borderless=False)
input_handler.bind(<green><green>'z'</green></green>, <green><green>'w'</green></green>)  <gray># <green><green>'z'</green></green>-key will now be registered as <green><green>'w'</green></green>-key</gray>
input_handler.bind(<green><green>'left mouse down'</green></green>, <green><green>'attack'</green></green>)  <gray># <green><green>'left mouse down'</green></green>-key will now send <green><green>'attack'</green></green>to input functions</gray>
input_handler.bind(<green><green>'gamepad b'</green></green>, <green><green>'attack'</green></green>)  <gray># <green><green>'gamepad b'</green></green>-key will now be registered as <green><green>'attack'</green></green>-key</gray>


<purple>def</purple> input(key):
    <blue>print</blue>(<green>'got key:'</green>, key)
    <purple>if</purple> key == <green>'attack'</green>:
        destroy(<olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.blue), dela<olive>y</olive>=.<yellow>2</yellow>)






app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="raycast">
        <h1>raycast</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/raycast.py"><gray>ursina/raycast</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;raycast(<gray>origin, direction:Vec3=(0,0,1), distance=9999, traverse_target:Entity=scene, ignore:list=None, debug=False, color=color.white</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(raycast_example)">copy</button><p id="raycast_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, <olive>Entity</olive>, held_keys, time, duplicate, camera, EditorCamera
app = Ursina()

<green><green>''</green>'
Casts a ray from *origin*, in *direction*, with length *distance* and returns
a HitInfo containing information about what it hit. This ray will only hit entities with a collider.

Use optional *traverse_target* to only be able to hit a specific entity and its children/descendants.
Use optional *ignore* list to ignore certain entities.
Setting debug to True will draw the line on screen.

Example where we only move if a wall is not hit:
<green>''</green>'</green>


class Player(<olive>Entity</olive>):

    <purple>def</purple> update(self):
        self.direction = Vec3(
            self.forward * (held_keys[<green>'w'</green>] - held_keys[<green>'s'</green>])
            + self.right * (held_keys[<green>'d'</green>] - held_keys[<green>'a'</green>])
            ).normalized()  <gray># get the direction we're trying to walk in.</gray>

        origin = self.world_position + (self.up*.5) <gray># the ray should start slightly up from the ground so we can walk up slopes or walk over small objects.</gray>
        hit_info = <purple><b>raycast</b></purple>(origin , self.direction, <olive>ignore</olive>=(self,), distance=.<yellow>5</yellow>, debug=False)
        <purple>if</purple> <purple>not</purple> hit_info.hit:
            self.position += self.direction * <yellow>5</yellow> * time.dt
        <purple>else</purple>:
            <blue>print</blue>(hit_info.entity)

Player(<olive>model</olive>=<green>'cube'</green>, origin_<olive>y</olive>=-.<yellow>5</yellow>, <olive>color</olive>=color.orange)
wall_left = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>collider</olive>=<green>'box'</green>, scale_<olive>y</olive>=<yellow>3</yellow>, origin_<olive>y</olive>=-.<yellow>5</yellow>, <olive>color</olive>=color.azure, x=-<yellow>4</yellow>)
wall_right = duplicate(wall_left, x=<yellow>4</yellow>)
camera.y = <yellow>2</yellow>
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="terraincast">
        <h1>terraincast</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/terraincast.py"><gray>ursina/terraincast</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;terraincast(<gray>world_position, terrain_entity, height_values=None, return_normals=False</gray>)</td> <td><span>uses x and z to return y on terrain.</span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(terraincast_example)">copy</button><p id="terraincast_example">app = Ursina()

terrain_entity = <olive>Entity</olive>(<olive>model</olive>=Terrain(<green>'heightmap_1'</green>, skip=<yellow>8</yellow>), <olive>scale</olive>=(<yellow>4</yellow><yellow>0</yellow>, <yellow>5</yellow>, <yellow>2</yellow><yellow>0</yellow>), <olive>texture</olive>=<green>'heightmap_1'</green>)
player = <olive>Entity</olive>(<olive>model</olive>=<green>'sphere'</green>, <olive>color</olive>=color.azure, <olive>scale</olive>=.<yellow>2</yellow>, origin_<olive>y</olive>=-.<yellow>5</yellow>)


hv = terrain_entity.model.height_values

<purple>def</purple> update():
    direction = Vec3(held_keys[<green>'d'</green>] - held_keys[<green>'a'</green>], <yellow>0</yellow>, held_keys[<green>'w'</green>] - held_keys[<green>'s'</green>]).normalized()
    player.position += direction * time.dt * <yellow>4</yellow>
    y = <purple><b>terraincast</b></purple>(player.world_position, terrain_entity, hv)
    <purple>if</purple> y is <purple>not</purple> None:
        player.y = y

EditorCamera()
<purple>from</purple> ursina.shaders <purple>import</purple> ssao_shader
camera.shader = ssao_shader
Sky()

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="boxcast">
        <h1>boxcast</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/boxcast.py"><gray>ursina/boxcast</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;boxcast(<gray>origin, direction=(0,0,1), distance=9999, thickness=(1,1), traverse_target=scene, ignore:list=None, debug=False</gray>)</td> <td><span>similar to raycast, but with width and height</span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(boxcast_example)">copy</button><p id="boxcast_example"><purple>from</purple> ursina <purple>import</purple> Ursina, held_keys, camera, duplicate, raycast, time, EditorCamera
app = Ursina()

<green><green>''</green>'
Casts a ray from *origin*, in *direction*, with length *distance* and returns
a HitInfo containing information about what it hit. This ray will only hit entities with a collider.

Use optional *traverse_target* to only be able to hit a specific entity and its children/descendants.
Use optional *ignore* list to ignore certain entities.
Setting debug to True will draw the line on screen.

Example where we only move if a wall is not hit:
<green>''</green>'</green>


class Player(<olive>Entity</olive>):

    <purple>def</purple> update(self):
        self.direction = Vec3(
            self.forward * (held_keys[<green>'w'</green>] - held_keys[<green>'s'</green>])
            + self.right * (held_keys[<green>'d'</green>] - held_keys[<green>'a'</green>])
            ).normalized()  <gray># get the direction we're trying to walk in.</gray>

        origin = self.world_position + (self.up*.5) <gray># the ray should start slightly up from the ground so we can walk up slopes or walk over small objects.</gray>
        hit_info = raycast(origin , self.direction, <olive>ignore</olive>=(self,), distance=.<yellow>5</yellow>, debug=False)
        <purple>if</purple> <purple>not</purple> hit_info.hit:
            self.position += self.direction * <yellow>5</yellow> * time.dt

Player(<olive>model</olive>=<green>'cube'</green>, origin_<olive>y</olive>=-.<yellow>5</yellow>, <olive>color</olive>=color.orange)
wall_left = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>collider</olive>=<green>'box'</green>, scale_<olive>y</olive>=<yellow>3</yellow>, origin_<olive>y</olive>=-.<yellow>5</yellow>, <olive>color</olive>=color.azure, x=-<yellow>4</yellow>)
wall_right = duplicate(wall_left, x=<yellow>4</yellow>)
camera.y = <yellow>2</yellow>
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Collider">
        <h1>Collider</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/collider.py"><gray>ursina/collider</gray></a><br><br>
        <div class="params">Collider(entity, shape)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.collision_node<gray> = CollisionNode('CollisionNode')</gray></td><td></td>
            </tr>
            <tr>
                <td>.shape<gray> = shape</gray></td><td></td>
            </tr>
            <tr>
                <td>.node_path<gray> = entity.attachNewNode(self.collision_node)</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.visible</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;remove()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Collider_example)">copy</button><p id="Collider_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, <olive>Entity</olive>, Pipe, Circle, Button, scene, EditorCamera, color
app = Ursina()

e = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'sphere'</green>, x=<yellow>2</yellow>)
e.collider = <green>'box'</green>          <gray># add BoxCollider based on entity's bounds.</gray>
e.collider = <green>'sphere'</green>       <gray># add SphereCollider based on entity's bounds.</gray>
e.collider = <green>'capsule'</green>      <gray># add CapsuleCollider based on entity's bounds.</gray>
e.collider = <green>'mesh'</green>         <gray># add MeshCollider matching the entity's model.</gray>
e.collider = <green>'file_name'</green>    <gray># load a model and us it as MeshCollider.</gray>
e.collider = e.model        <gray># copy target model/Mesh and use it as MeshCollider.</gray>

e.collider = Box<b>Collider</b>(e, center=Vec3(0,0,0), size=Vec3(1,1,1))   <gray># add BoxCollider at custom positions and size.</gray>
e.collider = Sphere<b>Collider</b>(e, center=Vec3(0,0,0), radius=.75)      <gray># add SphereCollider at custom positions and size.</gray>
e.collider = Capsule<b>Collider</b>(e, center=Vec3(0,0,0), height=3, radius=.75) <gray># add CapsuleCollider at custom positions and size.</gray>
e.collider = Mesh<b>Collider</b>(e, mesh=e.model, center=Vec3(0,0,0))      <gray># add MeshCollider with custom shape and center.</gray>

m = Pipe(base_shape=Circle(<yellow>6</yellow>), thicknesses=(<yellow>1</yellow>, .<yellow>5</yellow>))
e = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'cube'</green>, <olive>collider</olive>=<green>'mesh'</green>, <olive>color</olive>=color.red, <olive>highlight_color</olive>=color.yellow)

sphere = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'icosphere'</green>, <olive>collider</olive>=<green>'mesh'</green>, <olive>color</olive>=color.red, <olive>highlight_color</olive>=color.yellow, x=<yellow>4</yellow>)

EditorCamera()

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'c'</green>:
        e.collider = None



app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="BoxCollider">
        <h1>BoxCollider<a style="color: gray; font-weight:normal;" href="#Collider">(Collider)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/collider.py"><gray>ursina/collider</gray></a><br><br>
        <div class="params">BoxCollider(entity, center=(0,0,0), size=(1,1,1))</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.center<gray> = center</gray></td><td></td>
            </tr>
            <tr>
                <td>.size<gray> = size</gray></td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(BoxCollider_example)">copy</button><p id="BoxCollider_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, <olive>Entity</olive>, Pipe, Circle, Button, scene, EditorCamera, color
app = Ursina()

e = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'sphere'</green>, x=<yellow>2</yellow>)
e.collider = <green>'box'</green>          <gray># add BoxCollider based on entity's bounds.</gray>
e.collider = <green>'sphere'</green>       <gray># add SphereCollider based on entity's bounds.</gray>
e.collider = <green>'capsule'</green>      <gray># add CapsuleCollider based on entity's bounds.</gray>
e.collider = <green>'mesh'</green>         <gray># add MeshCollider matching the entity's model.</gray>
e.collider = <green>'file_name'</green>    <gray># load a model and us it as MeshCollider.</gray>
e.collider = e.model        <gray># copy target model/Mesh and use it as MeshCollider.</gray>

e.collider = <b>BoxCollider</b>(e, center=Vec3(0,0,0), size=Vec3(1,1,1))   <gray># add BoxCollider at custom positions and size.</gray>
e.collider = SphereCollider(e, center=Vec3(0,0,0), radius=.75)      <gray># add SphereCollider at custom positions and size.</gray>
e.collider = CapsuleCollider(e, center=Vec3(0,0,0), height=3, radius=.75) <gray># add CapsuleCollider at custom positions and size.</gray>
e.collider = MeshCollider(e, mesh=e.model, center=Vec3(0,0,0))      <gray># add MeshCollider with custom shape and center.</gray>

m = Pipe(base_shape=Circle(<yellow>6</yellow>), thicknesses=(<yellow>1</yellow>, .<yellow>5</yellow>))
e = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'cube'</green>, <olive>collider</olive>=<green>'mesh'</green>, <olive>color</olive>=color.red, <olive>highlight_color</olive>=color.yellow)

sphere = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'icosphere'</green>, <olive>collider</olive>=<green>'mesh'</green>, <olive>color</olive>=color.red, <olive>highlight_color</olive>=color.yellow, x=<yellow>4</yellow>)

EditorCamera()

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'c'</green>:
        e.collider = None



app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="SphereCollider">
        <h1>SphereCollider<a style="color: gray; font-weight:normal;" href="#Collider">(Collider)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/collider.py"><gray>ursina/collider</gray></a><br><br>
        <div class="params">SphereCollider(entity, center=(0,0,0), radius=.5)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.center<gray> = center</gray></td><td></td>
            </tr>
            <tr>
                <td>.radius<gray> = radius</gray></td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(SphereCollider_example)">copy</button><p id="SphereCollider_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, <olive>Entity</olive>, Pipe, Circle, Button, scene, EditorCamera, color
app = Ursina()

e = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'sphere'</green>, x=<yellow>2</yellow>)
e.collider = <green>'box'</green>          <gray># add BoxCollider based on entity's bounds.</gray>
e.collider = <green>'sphere'</green>       <gray># add SphereCollider based on entity's bounds.</gray>
e.collider = <green>'capsule'</green>      <gray># add CapsuleCollider based on entity's bounds.</gray>
e.collider = <green>'mesh'</green>         <gray># add MeshCollider matching the entity's model.</gray>
e.collider = <green>'file_name'</green>    <gray># load a model and us it as MeshCollider.</gray>
e.collider = e.model        <gray># copy target model/Mesh and use it as MeshCollider.</gray>

e.collider = BoxCollider(e, center=Vec3(0,0,0), size=Vec3(1,1,1))   <gray># add BoxCollider at custom positions and size.</gray>
e.collider = <b>SphereCollider</b>(e, center=Vec3(0,0,0), radius=.75)      <gray># add SphereCollider at custom positions and size.</gray>
e.collider = CapsuleCollider(e, center=Vec3(0,0,0), height=3, radius=.75) <gray># add CapsuleCollider at custom positions and size.</gray>
e.collider = MeshCollider(e, mesh=e.model, center=Vec3(0,0,0))      <gray># add MeshCollider with custom shape and center.</gray>

m = Pipe(base_shape=Circle(<yellow>6</yellow>), thicknesses=(<yellow>1</yellow>, .<yellow>5</yellow>))
e = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'cube'</green>, <olive>collider</olive>=<green>'mesh'</green>, <olive>color</olive>=color.red, <olive>highlight_color</olive>=color.yellow)

sphere = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'icosphere'</green>, <olive>collider</olive>=<green>'mesh'</green>, <olive>color</olive>=color.red, <olive>highlight_color</olive>=color.yellow, x=<yellow>4</yellow>)

EditorCamera()

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'c'</green>:
        e.collider = None



app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="MeshCollider">
        <h1>MeshCollider<a style="color: gray; font-weight:normal;" href="#Collider">(Collider)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/collider.py"><gray>ursina/collider</gray></a><br><br>
        <div class="params">MeshCollider(entity, mesh=None, center=(0,0,0))</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.center<gray> = center</gray></td><td></td>
            </tr>
            <tr>
                <td>.collision_polygons<gray> = []</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;remove()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(MeshCollider_example)">copy</button><p id="MeshCollider_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, <olive>Entity</olive>, Pipe, Circle, Button, scene, EditorCamera, color
app = Ursina()

e = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'sphere'</green>, x=<yellow>2</yellow>)
e.collider = <green>'box'</green>          <gray># add BoxCollider based on entity's bounds.</gray>
e.collider = <green>'sphere'</green>       <gray># add SphereCollider based on entity's bounds.</gray>
e.collider = <green>'capsule'</green>      <gray># add CapsuleCollider based on entity's bounds.</gray>
e.collider = <green>'mesh'</green>         <gray># add MeshCollider matching the entity's model.</gray>
e.collider = <green>'file_name'</green>    <gray># load a model and us it as MeshCollider.</gray>
e.collider = e.model        <gray># copy target model/Mesh and use it as MeshCollider.</gray>

e.collider = BoxCollider(e, center=Vec3(0,0,0), size=Vec3(1,1,1))   <gray># add BoxCollider at custom positions and size.</gray>
e.collider = SphereCollider(e, center=Vec3(0,0,0), radius=.75)      <gray># add SphereCollider at custom positions and size.</gray>
e.collider = CapsuleCollider(e, center=Vec3(0,0,0), height=3, radius=.75) <gray># add CapsuleCollider at custom positions and size.</gray>
e.collider = <b>MeshCollider</b>(e, mesh=e.model, center=Vec3(0,0,0))      <gray># add MeshCollider with custom shape and center.</gray>

m = Pipe(base_shape=Circle(<yellow>6</yellow>), thicknesses=(<yellow>1</yellow>, .<yellow>5</yellow>))
e = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'cube'</green>, <olive>collider</olive>=<green>'mesh'</green>, <olive>color</olive>=color.red, <olive>highlight_color</olive>=color.yellow)

sphere = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'icosphere'</green>, <olive>collider</olive>=<green>'mesh'</green>, <olive>color</olive>=color.red, <olive>highlight_color</olive>=color.yellow, x=<yellow>4</yellow>)

EditorCamera()

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'c'</green>:
        e.collider = None



app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Sky">
        <h1>Sky<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/sky.py"><gray>ursina/prefabs/sky</gray></a><br><br>
        <div class="params">Sky(**kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>Sky.instances = []</td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>

</div>
<br>
    <div class="class_box" id="EditorCamera">
        <h1>EditorCamera<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/editor_camera.py"><gray>ursina/prefabs/editor_camera</gray></a><br><br>
        <div class="params">EditorCamera(**kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.rotation_speed<gray> = 200</gray></td><td></td>
            </tr>
            <tr>
                <td>.pan_speed<gray> = Vec2(5, 5)</gray></td><td></td>
            </tr>
            <tr>
                <td>.move_speed<gray> = 10</gray></td><td></td>
            </tr>
            <tr>
                <td>.target_fov<gray> = camera.fov</gray></td><td></td>
            </tr>
            <tr>
                <td>.zoom_speed<gray> = 1.25</gray></td><td></td>
            </tr>
            <tr>
                <td>.zoom_smoothing<gray> = 8</gray></td><td></td>
            </tr>
            <tr>
                <td>.rotate_around_mouse_hit<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.ignore_scroll_on_ui<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.smoothing_helper<gray> = Entity(add_to_scene_entities=False)</gray></td><td></td>
            </tr>
            <tr>
                <td>.rotation_smoothing<gray> = 0</gray></td><td></td>
            </tr>
            <tr>
                <td>.look_at<gray> = self.smoothing_helper.look_at</gray></td><td></td>
            </tr>
            <tr>
                <td>.look_at_2d<gray> = self.smoothing_helper.look_at_2d</gray></td><td></td>
            </tr>
            <tr>
                <td>.rotate_key<gray> = 'right mouse'</gray></td><td></td>
            </tr>
            <tr>
                <td>.start_position<gray> = self.position</gray></td><td></td>
            </tr>
            <tr>
                <td>.perspective_fov<gray> = camera.fov</gray></td><td></td>
            </tr>
            <tr>
                <td>.orthographic_fov<gray> = camera.fov</gray></td><td></td>
            </tr>
            <tr>
                <td>.on_destroy<gray> = self.on_disable</gray></td><td></td>
            </tr>
            <tr>
                <td>.shortcuts<gray> = {'toggle_orthographic':'shift+p', 'focus':'shift+f', 'reset_center':'alt+f'}</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;on_enable()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_disable()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_destroy()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(EditorCamera_example)">copy</button><p id="EditorCamera_example"><purple>from</purple> ursina <purple>import</purple> Ursina, Sky, load_model, color, Text, window, Button
app = Ursina(vsync=False, use_ingame_console=True)
<green><green>''</green>'
Simple camera for debugging.
Hold right click and move the mouse to rotate around point.
<green>''</green>'</green>

sky = Sky()
e = <olive>Entity</olive>(<olive>model</olive>=load_model(<green>'cube'</green>, use_deepcop<olive>y</olive>=True), <olive>color</olive>=color.white, <olive>collider</olive>=<green>'box'</green>)
e.model.colorize()

ground = <olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>scale</olive>=<yellow>3</yellow><yellow>2</yellow>, <olive>texture</olive>=<green>'white_cube'</green>, <olive>texture_scale</olive>=(<yellow>3</yellow><yellow>2</yellow>,<yellow>3</yellow><yellow>2</yellow>), <olive>collider</olive>=<green>'box'</green>)
box = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>collider</olive>=<green>'box'</green>, <olive>texture</olive>=<green>'white_cube'</green>, <olive>scale</olive>=(<yellow>1</yellow><yellow>0</yellow>,<yellow>2</yellow>,<yellow>2</yellow>), <olive>position</olive>=(<yellow>2</yellow>,<yellow>1</yellow>,<yellow>5</yellow>), <olive>color</olive>=color.light_gray)

b = Button(<olive>position</olive>=window.top_left, <olive>scale</olive>=.<yellow>0</yellow><yellow>5</yellow>)
ec = <purple><b>EditorCamera</b></purple>(ignore_scroll_on_ui=True)
rotation_info = Text(<olive>position</olive>=window.top_left)

<purple>def</purple> update():
    rotation_info.text = str(int(ec.rotation_y)) + <green>'\n'</green> + str(int(ec.rotation_x))


app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Tilemap">
        <h1>Tilemap<a style="color: gray; font-weight:normal;" href="#GridEditor">(GridEditor)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/tilemap.py"><gray>ursina/prefabs/tilemap</gray></a><br><br>
        <div class="params">Tilemap(tilemap='', tileset='', tileset_size=(8,8), **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.grid<gray> = [[self.tilemap.get_pixel(x,y) for y in range(self.tilemap.height)] for x in range(self.tilemap.width)]</gray></td><td></td>
            </tr>
            <tr>
                <td>.tileset<gray> = tileset</gray></td><td></td>
            </tr>
            <tr>
                <td>.tileset_size<gray> = tileset_size</gray></td><td></td>
            </tr>
            <tr>
                <td>.model<gray> = Mesh()</gray></td><td></td>
            </tr>
            <tr>
                <td>.texture<gray> = tileset</gray></td><td></td>
            </tr>
            <tr>
                <td>.colliders<gray> = list()</gray></td><td></td>
            </tr>
            <tr>
                <td>.auto_render<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.outline<gray> = Entity(parent=self, model=Quad(segments=0, mode='line', thickness=1), color=color.cyan, z=.01, origin=(-.5,-.5), enabled=self.edit_mode)</gray></td><td></td>
            </tr>
            <tr>
                <td>.uv_dict<gray> = {
        '11111111' : [(4,1), (5,1), (6,1), (7,1)],     </gray></td><td><span>fill</span></td>
            </tr>
            <tr>
                <td>.single_block_coordinates<gray> = [(4,0), (5,0), (6,0), (7,0)]</gray></td><td></td>
            </tr>
            <tr>
                <td>.variation_chance<gray> = [0,0,0,0,1,1,1,2,2,3]</gray></td><td></td>
            </tr>
            <tr>
                <td>.uv_margin<gray> = .002</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;draw_temp(<gray>position</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;render()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;save()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Tilemap_example)">copy</button><p id="Tilemap_example">app = Ursina()
EditorCamera()
tilemap = <purple><b>Tilemap</b></purple>(<green>'tilemap_test_level'</green>, tileset=<green>'test_tileset'</green>, tileset_size=(<yellow>8</yellow>,<yellow>4</yellow>), <olive>parent</olive>=scene)
tilemap.canvas.texture = <green>'tilemap_test_level'</green>
camera.orthographic = True
camera.position = tilemap.tilemap.size / <yellow>2</yellow>
camera.fov = tilemap.tilemap.height

Text(<green>'press tab to toggle edit mode'</green>, <olive>origin</olive>=(.<yellow>5</yellow>,<yellow>0</yellow>), <olive>position</olive>=(-.<yellow>5</yellow><yellow>5</yellow>,.<yellow>4</yellow>))

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="FirstPersonController">
        <h1>FirstPersonController<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/first_person_controller.py"><gray>ursina/prefabs/first_person_controller</gray></a><br><br>
        <div class="params">FirstPersonController(**kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.cursor<gray> = Entity(parent=camera.ui, model='quad', color=color.pink, scale=.008, rotation_z=45)</gray></td><td></td>
            </tr>
            <tr>
                <td>.speed<gray> = 5</gray></td><td></td>
            </tr>
            <tr>
                <td>.height<gray> = 2</gray></td><td></td>
            </tr>
            <tr>
                <td>.camera_pivot<gray> = Entity(parent=self, y=self.height)</gray></td><td></td>
            </tr>
            <tr>
                <td>.mouse_sensitivity<gray> = Vec2(40, 40)</gray></td><td></td>
            </tr>
            <tr>
                <td>.gravity<gray> = 1</gray></td><td></td>
            </tr>
            <tr>
                <td>.grounded<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.jump_height<gray> = 2</gray></td><td></td>
            </tr>
            <tr>
                <td>.jump_up_duration<gray> = .5</gray></td><td></td>
            </tr>
            <tr>
                <td>.fall_after<gray> = .35 </gray></td><td><span>will interrupt jump up</span></td>
            </tr>
            <tr>
                <td>.jumping<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.air_time<gray> = 0</gray></td><td></td>
            </tr>
            <tr>
                <td>.traverse_target<gray> = scene     </gray></td><td><span>by default, it will collide with everything. change this to change the raycasts' traverse targets.</span></td>
            </tr>
            <tr>
                <td>.ignore_list<gray> = [self, ]</gray></td><td></td>
            </tr>
            <tr>
                <td>.on_destroy<gray> = self.on_disable</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;jump()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;start_fall()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;land()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_enable()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_disable()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(FirstPersonController_example)">copy</button><p id="FirstPersonController_example"><purple>from</purple> ursina.prefabs.first_person_controller <purple>import</purple> FirstPersonController
window.vsync = False
app = Ursina()
ground = <olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>scale</olive>=(<yellow>1</yellow><yellow>0</yellow><yellow>0</yellow>,<yellow>1</yellow>,<yellow>1</yellow><yellow>0</yellow><yellow>0</yellow>), <olive>color</olive>=color.yellow.tint(-.<yellow>2</yellow>), <olive>texture</olive>=<green>'white_cube'</green>, <olive>texture_scale</olive>=(<yellow>1</yellow><yellow>0</yellow><yellow>0</yellow>,<yellow>1</yellow><yellow>0</yellow><yellow>0</yellow>), <olive>collider</olive>=<green>'box'</green>)
e = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>scale</olive>=(<yellow>1</yellow>,<yellow>5</yellow>,<yellow>1</yellow><yellow>0</yellow>), x=<yellow>2</yellow>, <olive>y</olive>=.<yellow>0</yellow><yellow>1</yellow>, rotation_<olive>y</olive>=<yellow>4</yellow><yellow>5</yellow>, <olive>collider</olive>=<green>'box'</green>, <olive>texture</olive>=<green>'white_cube'</green>)
e.texture_scale = (e.scale_z, e.scale_y)
e = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>scale</olive>=(<yellow>1</yellow>,<yellow>5</yellow>,<yellow>1</yellow><yellow>0</yellow>), x=-<yellow>2</yellow>, <olive>y</olive>=.<yellow>0</yellow><yellow>1</yellow>, <olive>collider</olive>=<green>'box'</green>, <olive>texture</olive>=<green>'white_cube'</green>)
e.texture_scale = (e.scale_z, e.scale_y)

player = <purple><b>FirstPersonController</b></purple>(<olive>y</olive>=<yellow>2</yellow>, origin_<olive>y</olive>=-.<yellow>5</yellow>)
player.gun = None


gun = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.blue, origin_<olive>y</olive>=-.<yellow>5</yellow>, <olive>position</olive>=(<yellow>3</yellow>,<yellow>0</yellow>,<yellow>3</yellow>), <olive>collider</olive>=<green>'box'</green>, <olive>scale</olive>=(.<yellow>2</yellow>,.<yellow>2</yellow>,<yellow>1</yellow>))
<purple>def</purple> get_gun():
    gun.parent = camera
    gun.position = Vec3(.<yellow>5</yellow>,<yellow>0</yellow>,.<yellow>5</yellow>)
    player.gun = gun
gun.on_click = get_gun

gun_<yellow>2</yellow> = duplicate(gun, <olive>z</olive>=<yellow>7</yellow>, x=<yellow>8</yellow>)
slope = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>collider</olive>=<green>'box'</green>, <olive>position</olive>=(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>8</yellow>), <olive>scale</olive>=<yellow>6</yellow>, <olive>rotation</olive>=(<yellow>4</yellow><yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), <olive>texture</olive>=<green>'brick'</green>, <olive>texture_scale</olive>=(<yellow>8</yellow>,<yellow>8</yellow>))
slope = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>collider</olive>=<green>'box'</green>, <olive>position</olive>=(<yellow>5</yellow>,<yellow>0</yellow>,<yellow>1</yellow><yellow>0</yellow>), <olive>scale</olive>=<yellow>6</yellow>, <olive>rotation</olive>=(<yellow>8</yellow><yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>), <olive>texture</olive>=<green>'brick'</green>, <olive>texture_scale</olive>=(<yellow>8</yellow>,<yellow>8</yellow>))

hookshot_target = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.brown, <olive>position</olive>=(<yellow>4</yellow>,<yellow>5</yellow>,<yellow>5</yellow>))
hookshot_target.on_click = Func(player.animate_position, hookshot_target.position, duration=.<yellow>5</yellow>, <olive>curve</olive>=curve.linear)

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'left mouse down'</green> and player.gun:
        gun.blink(color.orange)
        bullet = <olive>Entity</olive>(<olive>parent</olive>=gun, <olive>model</olive>=<green>'cube'</green>, <olive>scale</olive>=.<yellow>1</yellow>, <olive>color</olive>=color.black)
        bullet.world_parent = scene
        bullet.animate_position(bullet.position+(bullet.forward*<yellow>5</yellow><yellow>0</yellow>), <olive>curve</olive>=curve.linear, duration=<yellow>1</yellow>)
        destroy(bullet, dela<olive>y</olive>=<yellow>1</yellow>)

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="PlatformerController2d">
        <h1>PlatformerController2d<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/platformer_controller_2d.py"><gray>ursina/prefabs/platformer_controller_2d</gray></a><br><br>
        <div class="params">PlatformerController2d(**kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.model<gray> = 'cube'</gray></td><td></td>
            </tr>
            <tr>
                <td>.origin_y<gray> = -.5</gray></td><td></td>
            </tr>
            <tr>
                <td>.scale_y<gray> = 2</gray></td><td></td>
            </tr>
            <tr>
                <td>.color<gray> = color.orange</gray></td><td></td>
            </tr>
            <tr>
                <td>.collider<gray> = 'box'</gray></td><td></td>
            </tr>
            <tr>
                <td>.animator<gray> = Animator({'idle' : None, 'walk' : None, 'jump' : None})</gray></td><td></td>
            </tr>
            <tr>
                <td>.walk_speed<gray> = 8</gray></td><td></td>
            </tr>
            <tr>
                <td>.walking<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.velocity<gray> = 0 </gray></td><td><span>the walk direction is stored here. -1 for left and 1 for right.</span></td>
            </tr>
            <tr>
                <td>.jump_height<gray> = 4</gray></td><td></td>
            </tr>
            <tr>
                <td>.jump_duration<gray> = .5</gray></td><td></td>
            </tr>
            <tr>
                <td>.jumping<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.max_jumps<gray> = 1</gray></td><td></td>
            </tr>
            <tr>
                <td>.jumps_left<gray> = self.max_jumps</gray></td><td></td>
            </tr>
            <tr>
                <td>.gravity<gray> = 1</gray></td><td></td>
            </tr>
            <tr>
                <td>.grounded<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.air_time<gray> = 0   </gray></td><td><span>this increase while we're falling and used when calculating the distance we fall so we fall faster and faster instead of linearly.</span></td>
            </tr>
            <tr>
                <td>.traverse_target<gray> = scene     </gray></td><td><span>by default, it will collide with everything except itself. you can change this to change the boxcast traverse target.</span></td>
            </tr>
            <tr>
                <td>.ignore_list<gray> = [self, ]</gray></td><td></td>
            </tr>
            <tr>
                <td>.gravity<gray> = 0</gray></td><td></td>
            </tr>
            <tr>
                <td>.min_x<gray> = -99999</gray></td><td></td>
            </tr>
            <tr>
                <td>.max_x<gray> = 99999</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;jump()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;start_fall()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;land()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(PlatformerController2d_example)">copy</button><p id="PlatformerController2d_example">app = Ursina()
camera.orthographic = True
camera.fov = <yellow>1</yellow><yellow>0</yellow>

ground = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.white<yellow>3</yellow><yellow>3</yellow>, origin_<olive>y</olive>=.<yellow>5</yellow>, <olive>scale</olive>=(<yellow>2</yellow><yellow>0</yellow>, <yellow>1</yellow>, <yellow>1</yellow>), <olive>collider</olive>=<green>'box'</green>, <olive>y</olive>=-<yellow>1</yellow>)
wall = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.azure, <olive>origin</olive>=(-.<yellow>5</yellow>,.<yellow>5</yellow>), <olive>scale</olive>=(<yellow>5</yellow>,<yellow>1</yellow><yellow>0</yellow>), x=<yellow>1</yellow><yellow>0</yellow>, <olive>y</olive>=.<yellow>5</yellow>, <olive>collider</olive>=<green>'box'</green>)
wall_<yellow>2</yellow> = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.white<yellow>3</yellow><yellow>3</yellow>, <olive>origin</olive>=(-.<yellow>5</yellow>,.<yellow>5</yellow>), <olive>scale</olive>=(<yellow>5</yellow>,<yellow>1</yellow><yellow>0</yellow>), x=<yellow>1</yellow><yellow>0</yellow>, <olive>y</olive>=<yellow>0</yellow>, <olive>collider</olive>=<green>'box'</green>)
ceiling = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.white<yellow>3</yellow><yellow>3</yellow>, origin_<olive>y</olive>=-.<yellow>5</yellow>, <olive>scale</olive>=(<yellow>1</yellow>, <yellow>1</yellow>, <yellow>1</yellow>), <olive>y</olive>=<yellow>1</yellow>, <olive>collider</olive>=<green>'box'</green>)
ceiling = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.white<yellow>3</yellow><yellow>3</yellow>, origin_<olive>y</olive>=-.<yellow>5</yellow>, <olive>scale</olive>=(<yellow>5</yellow>, <yellow>5</yellow>, <yellow>1</yellow>), <olive>y</olive>=<yellow>2</yellow>, <olive>collider</olive>=<green>'box'</green>)
ground = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.white<yellow>3</yellow><yellow>3</yellow>, origin_<olive>y</olive>=.<yellow>5</yellow>, <olive>scale</olive>=(<yellow>2</yellow><yellow>0</yellow>, <yellow>3</yellow>, <yellow>1</yellow>), <olive>collider</olive>=<green>'box'</green>, <olive>y</olive>=-<yellow>1</yellow>, rotation_<olive>z</olive>=<yellow>4</yellow><yellow>5</yellow>, x=-<yellow>5</yellow>)

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'c'</green>:
        wall.collision = <purple>not</purple> wall.collision
        <blue>print</blue>(wall.collision)


player_controller = PlatformerController<yellow>2</yellow>d(scale_<olive>y</olive>=<yellow>2</yellow>, jump_height=<yellow>4</yellow>, x=<yellow>3</yellow>, <olive>y</olive>=<yellow>2</yellow><yellow>0</yellow>, max_jumps=<yellow>2</yellow>)
ec = EditorCamera()
ec.add_script(SmoothFollow(target=player_controller, offset=[<yellow>0</yellow>,<yellow>1</yellow>,<yellow>0</yellow>], speed=<yellow>4</yellow>))

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Conversation">
        <h1>Conversation<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/conversation.py"><gray>ursina/prefabs/conversation</gray></a><br><br>
        <div class="params">Conversation(variables_object=None, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.question<gray> = Button(parent=self, text_origin=(-.5,0), scale=(1,.1), model=Quad(radius=.5,aspect=1/.1), text='Question')</gray></td><td></td>
            </tr>
            <tr>
                <td>.more_indicator<gray> = Entity(parent=self.question, model=Circle(3), position=(.45,-.4,-1), rotation_z=180, color=color.azure, world_scale=.5, z=-1, enabled=False)</gray></td><td></td>
            </tr>
            <tr>
                <td>.spacing<gray> = 4 * .02</gray></td><td></td>
            </tr>
            <tr>
                <td>.wordwrap<gray> = 65</gray></td><td></td>
            </tr>
            <tr>
                <td>.button_model<gray> = Quad(radius=.5, aspect=1/.075)</gray></td><td></td>
            </tr>
            <tr>
                <td>.variables_object<gray> = variables_object</gray></td><td></td>
            </tr>
            <tr>
                <td>.answer_0<gray> = Button(parent=self, text='answer_0', y=self.question.y-self.spacing-.025, scale=(1,.075), text_origin=(-.5,0), model=copy(self.button_model))</gray></td><td></td>
            </tr>
            <tr>
                <td>.answer_1<gray> = Button(parent=self, text='answer_1', y=self.answer_0.y-self.spacing, scale=(1,.075), text_origin=(-.5,0), model=copy(self.button_model))</gray></td><td></td>
            </tr>
            <tr>
                <td>.answer_2<gray> = Button(parent=self, text='answer_2', y=self.answer_1.y-self.spacing, scale=(1,.075), text_origin=(-.5,0), model=copy(self.button_model))</gray></td><td></td>
            </tr>
            <tr>
                <td>.buttons<gray> = (self.answer_0, self.answer_1, self.answer_2)</gray></td><td></td>
            </tr>
            <tr>
                <td>.question_appear_sequence<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.button_appear_sequence<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.started<gray> = False</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;ask(<gray>node, question_part=0</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_click(<gray>node=child</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;next()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;start_conversation(<gray>conversation</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;parse_conversation(<gray>convo</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Conversation_example)">copy</button><p id="Conversation_example">app = Ursina()

variables = Empty(
    evil=<yellow>0</yellow>,
    chaos=<yellow>0</yellow>,
    bar_mission_solved=False,
)
conversation = <purple><b>Conversation</b></purple>(variables_object=variables)

convo = dedent(<green><green>''</green>'
I<green>'m looking for my sister. Can you help me find her, please? I haven'</green>t seen her in days! Who know what could've happened!?
I'm worried. Will you help me?
    * Yes, of course. This can be a dangerous city.
        Oh no! Do you think something happened to her?
        What should I do?!
            * She's probably fine. She can handle herself.
                You<green>'re right. I'</green>m still worried though.
                    * Don<green>'t worry, I'</green>ll look for her.
            * Maybe. (stats.chaos += 1)
                Help me look for her, please! *runs off*
    * I<green>'m sorry, but I don'</green>t have time right now. (evil += 1)
        A true friend wouldn't say that.
    * I know where she is! (if bar_mission_solved)
        Really? Where?
            * I saw her on a ship by the docks, it looked like they were ready to set off.
                Thank you! *runs off*
<green>''</green>'</green>)
conversation.start_conversation(convo)




<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'space'</green>:
        <blue>print</blue>(variables.evil)

Sprite(<green>'shore'</green>, <olive>z</olive>=<yellow>1</yellow>)
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Button">
        <h1>Button<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/button.py"><gray>ursina/prefabs/button</gray></a><br><br>
        <div class="params">Button(text='', parent=camera.ui, model=Default, radius=.1, origin=(0,0), text_origin=(0,0), text_size=1, color=Default, collider='box', highlight_scale=1, pressed_scale=1, disabled=False, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.origin<gray> = origin</gray></td><td></td>
            </tr>
            <tr>
                <td>.color<gray> = color</gray></td><td></td>
            </tr>
            <tr>
                <td>.highlight_color<gray> = self.color.tint(.2)</gray></td><td></td>
            </tr>
            <tr>
                <td>.pressed_color<gray> = self.color.tint(-.2)</gray></td><td></td>
            </tr>
            <tr>
                <td>.highlight_scale<gray> = highlight_scale    </gray></td><td><span>multiplier</span></td>
            </tr>
            <tr>
                <td>.pressed_scale<gray> = pressed_scale     </gray></td><td><span>multiplier</span></td>
            </tr>
            <tr>
                <td>.highlight_sound<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.pressed_sound<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.collider<gray> = collider</gray></td><td></td>
            </tr>
            <tr>
                <td>.disabled<gray> = disabled</gray></td><td></td>
            </tr>
            <tr>
                <td>.text_entity<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.text_origin<gray> = text_origin</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.text</td><td><span></span></td>
            </tr>
            <tr>
                <td>.text_origin</td><td><span></span></td>
            </tr>
            <tr>
                <td>.text_color</td><td><span></span></td>
            </tr>
            <tr>
                <td>.icon</td><td><span></span></td>
            </tr>
            <tr>
                <td>.icon_world_scale</td><td><span></span></td>
            </tr>
            <tr>
                <td>.text_size</td><td><span></span></td>
            </tr>
            <tr>
                <td>.origin</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_mouse_enter()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_mouse_exit()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;fit_to_text(<gray>radius=.1, padding=Vec2(Text.size*1.5, Text.size)</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Button_example)">copy</button><p id="Button_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()

Button.default_color = color.red
b = <purple><b>Button</b></purple>(<olive>model</olive>=<green>'quad'</green>, <olive>scale</olive>=.<yellow>0</yellow><yellow>5</yellow>, x=-.<yellow>5</yellow>, <olive>color</olive>=color.lime, <olive>text</olive>=<green>'text scale\ntest'</green>, text_size=.<yellow>5</yellow>, text_<olive>color</olive>=color.black)
b.text_size = .<yellow>5</yellow>
b.on_click = Sequence(Wait(.<yellow>5</yellow>), Func(print, <green>'aaaaaa'</green>), )

b = <purple><b>Button</b></purple>(<olive>parent</olive>=camera.ui, <olive>text</olive>=<green>'hello world!'</green>, <olive>scale</olive>=.<yellow>2</yellow><yellow>5</yellow>)
Button.default_color = color.blue
b = <purple><b>Button</b></purple>(<olive>text</olive>=<green>'hello world!'</green>, <olive>icon</olive>=<green>'sword'</green>, <olive>scale</olive>=.<yellow>2</yellow><yellow>5</yellow>, text_<olive>origin</olive>=(-.<yellow>5</yellow>,<yellow>0</yellow>), x=.<yellow>5</yellow>)
b.on_click = application.quit <gray># assign a function to the button.</gray>
b.tooltip = Tooltip(<green>'exit'</green>)

par = <olive>Entity</olive>(<olive>parent</olive>=camera.ui, <olive>scale</olive>=.<yellow>2</yellow>, <olive>y</olive>=-.<yellow>2</yellow>)
b = <purple><b>Button</b></purple>(<olive>parent</olive>=par, <olive>text</olive>=<green>'test'</green>, <olive>scale_x</olive>=<yellow>1</yellow>, <olive>origin</olive>=(-.<yellow>5</yellow>,.<yellow>5</yellow>))
b.text =<green>'new text'</green>
<blue>print</blue>(b.text_entity)

<purple><b>Button</b></purple>(<olive>text</olive>=<green>'sound'</green>, <olive>scale</olive>=.<yellow>2</yellow>, <olive>position</olive>=(-.<yellow>2</yellow><yellow>5</yellow>,-.<yellow>2</yellow>), <olive>color</olive>=color.pink, highlight_sound=<green>'blip_1'</green>, pressed_sound=Audio(<green>'coin_1'</green>, autopla<olive>y</olive>=False))

Text(<green>'Text size\nreference'</green>, x=.<yellow>1</yellow><yellow>5</yellow>)
<purple>def</purple> input(key):

    <purple>if</purple> key == <green>'d'</green>:
        scene.clear()

    <purple>if</purple> key == <green>'space'</green>:
        b.text = <green>'updated text'</green>


app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Draggable">
        <h1>Draggable<a style="color: gray; font-weight:normal;" href="#Button">(Button)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/draggable.py"><gray>ursina/prefabs/draggable</gray></a><br><br>
        <div class="params">Draggable(**kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.require_key<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.dragging<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.delta_drag<gray> = 0</gray></td><td></td>
            </tr>
            <tr>
                <td>.start_pos<gray> = self.world_position</gray></td><td></td>
            </tr>
            <tr>
                <td>.start_offset<gray> = (0,0,0)</gray></td><td></td>
            </tr>
            <tr>
                <td>.step<gray> = (0,0,0)</gray></td><td></td>
            </tr>
            <tr>
                <td>.plane_direction<gray> = (0,0,1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.lock<gray> = Vec3(0,0,0)     </gray></td><td><span>set to 1 to lock movement on any of x, y and z axes</span></td>
            </tr>
            <tr>
                <td>.min_x, self.min_y, self.min_z<gray> = -inf, -inf, -inf</gray></td><td></td>
            </tr>
            <tr>
                <td>.max_x, self.max_y, self.max_z<gray> = inf, inf, inf</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.step</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;start_dragging()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;stop_dragging()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Draggable_example)">copy</button><p id="Draggable_example">app = Ursina()

<olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>scale</olive>=<yellow>8</yellow>, <olive>texture</olive>=<green>'white_cube'</green>, <olive>texture_scale</olive>=(<yellow>8</yellow>,<yellow>8</yellow>))
draggable_button = <purple><b>Draggable</b></purple>(<olive>scale</olive>=.<yellow>1</yellow>, <olive>text</olive>=<green>'drag me'</green>, <olive>position</olive>=(-.<yellow>5</yellow>, <yellow>0</yellow>))
world_space_draggable = <purple><b>Draggable</b></purple>(<olive>parent</olive>=scene, <olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.azure, plane_direction=(<yellow>0</yellow>,<yellow>1</yellow>,<yellow>0</yellow>), lock=(<yellow>1</yellow>,<yellow>0</yellow>,<yellow>0</yellow>))

EditorCamera(<olive>rotation</olive>=(<yellow>3</yellow><yellow>0</yellow>,<yellow>1</yellow><yellow>0</yellow>,<yellow>0</yellow>))
world_space_draggable.drop = Func(print, <green>'dropped cube'</green>)

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Tooltip">
        <h1>Tooltip<a style="color: gray; font-weight:normal;" href="#Text">(Text)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/tooltip.py"><gray>ursina/prefabs/tooltip</gray></a><br><br>
        <div class="params">Tooltip(text='', wordwrap=40, background_color=color.black66, **kwargs)</div><br>
        <table> <!-- attributes -->
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Tooltip_example)">copy</button><p id="Tooltip_example">app = Ursina()

    tooltip_test = <purple><b>Tooltip</b></purple>(
    <green>'&ltscale:1.5&gt&ltpink&gt'</green> + <green>'Rainstorm'</green> + <green>'&ltscale:1&gt \n \n'</green> +
<green><green>''</green>'Summon a &ltblue&gtrain
storm &ltdefault&gtto deal 5 &ltblue&gtwater
damage &ltdefault&gtto &ltred&gteveryone, &ltdefault&gtincluding &ltorange&gtyourself. &ltdefault&gt
Lasts for 4 rounds.<green>''</green><green>'</green>.replace('</green>\n<green>', '</green> '),
        background_<olive>color</olive>=color.violet,
        font=<green>'VeraMono.ttf'</green>,
        wordwrap=<yellow>5</yellow><yellow>0</yellow>,
)

    tooltip_test.enabled = True
    app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Slider">
        <h1>Slider<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/slider.py"><gray>ursina/prefabs/slider</gray></a><br><br>
        <div class="params">Slider(min=0, max=1, default=None, height=Text.size, text='', dynamic=False, radius=Text.size/2, bar_color=color.black66, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.parent<gray> = camera.ui</gray></td><td></td>
            </tr>
            <tr>
                <td>.vertical<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.min<gray> = min</gray></td><td></td>
            </tr>
            <tr>
                <td>.max<gray> = max</gray></td><td></td>
            </tr>
            <tr>
                <td>.default<gray> = default</gray></td><td></td>
            </tr>
            <tr>
                <td>.step<gray> = 0                   </gray></td><td><span>for example, setting .step to 1, would make the slider snap to the closest integer.</span></td>
            </tr>
            <tr>
                <td>.height<gray> = height</gray></td><td></td>
            </tr>
            <tr>
                <td>.on_value_changed<gray> = None    </gray></td><td><span>set this to a function you want to be called when the slider changes</span></td>
            </tr>
            <tr>
                <td>.setattr<gray> = None             </gray></td><td><span>set this to (object, 'attrname') to set that value when the slider changes</span></td>
            </tr>
            <tr>
                <td>.label<gray> = Text(parent=self, origin=(0.5, 0), x=-0.025, text=text)</gray></td><td></td>
            </tr>
            <tr>
                <td>.bg<gray> = Entity(parent=self, model=Quad(scale=(.525, height), radius=radius, segments=3),
        origin_x=-0.25, collider='box', color=bar_color)</gray></td><td></td>
            </tr>
            <tr>
                <td>.knob<gray> = Draggable(parent=self, min_x=0, max_x=.5, min_y=0, max_y=.5, step=self.step,
        model=Quad(radius=Text.size/2, scale=(Text.size, height)), collider='box', color=color.light_gray,
        text='0', text_origin=(0, -.55), z=-.1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.value<gray> = self.default</gray></td><td></td>
            </tr>
            <tr>
                <td>.dynamic<gray> = dynamic    </gray></td><td><span>if set to True, will call on_value_changed() while dragging. if set to False, will only call on_value_changed() after dragging.</span></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.value</td><td><span></span></td>
            </tr>
            <tr>
                <td>.step</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;bg_click()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;drop()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;slide()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Slider_example)">copy</button><p id="Slider_example">app = Ursina()

box = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, origin_<olive>y</olive>=-.<yellow>5</yellow>, <olive>scale</olive>=<yellow>1</yellow>, <olive>color</olive>=color.orange)

<purple>def</purple> scale_box():
    box.scale_y = slider.value
    <blue>print</blue>(thin_slider.value)

slider = <purple><b>Slider</b></purple>(<yellow>0</yellow>, <yellow>2</yellow><yellow>0</yellow>, default=<yellow>1</yellow><yellow>0</yellow>, height=Text.size*<yellow>3</yellow>, <olive>y</olive>=-.<yellow>4</yellow>, step=<yellow>1</yellow>, on_value_changed=scale_box, vertical=True)

thin_slider = Thin<purple><b>Slider</b></purple>(<olive>text</olive>=<green>'height'</green>, dynamic=True, on_value_changed=scale_box)

thin_slider.label.origin = (<yellow>0</yellow>,<yellow>0</yellow>)
thin_slider.label.position = (.<yellow>2</yellow><yellow>5</yellow>, -.<yellow>1</yellow>)

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="ThinSlider">
        <h1>ThinSlider<a style="color: gray; font-weight:normal;" href="#Slider">(Slider)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/slider.py"><gray>ursina/prefabs/slider</gray></a><br><br>
        <div class="params">ThinSlider(*args, **kwargs)</div><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(ThinSlider_example)">copy</button><p id="ThinSlider_example">app = Ursina()

box = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, origin_<olive>y</olive>=-.<yellow>5</yellow>, <olive>scale</olive>=<yellow>1</yellow>, <olive>color</olive>=color.orange)

<purple>def</purple> scale_box():
    box.scale_y = slider.value
    <blue>print</blue>(thin_slider.value)

slider = Slider(<yellow>0</yellow>, <yellow>2</yellow><yellow>0</yellow>, default=<yellow>1</yellow><yellow>0</yellow>, height=Text.size*<yellow>3</yellow>, <olive>y</olive>=-.<yellow>4</yellow>, step=<yellow>1</yellow>, on_value_changed=scale_box, vertical=True)

thin_slider = <purple><b>ThinSlider</b></purple>(<olive>text</olive>=<green>'height'</green>, dynamic=True, on_value_changed=scale_box)

thin_slider.label.origin = (<yellow>0</yellow>,<yellow>0</yellow>)
thin_slider.label.position = (.<yellow>2</yellow><yellow>5</yellow>, -.<yellow>1</yellow>)

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="TextField">
        <h1>TextField<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/text_field.py"><gray>ursina/prefabs/text_field</gray></a><br><br>
        <div class="params">TextField(max_lines=64, line_height=1.1, character_limit=None, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.font<gray> = 'VeraMono.ttf'</gray></td><td></td>
            </tr>
            <tr>
                <td>.line_height<gray> = line_height</gray></td><td></td>
            </tr>
            <tr>
                <td>.max_lines<gray> = max_lines</gray></td><td></td>
            </tr>
            <tr>
                <td>.character_limit<gray> = character_limit</gray></td><td></td>
            </tr>
            <tr>
                <td>.scroll_parent<gray> = Entity(parent=self)</gray></td><td></td>
            </tr>
            <tr>
                <td>.text_entity<gray> = Text(parent=self.scroll_parent, start_tag='☾', end_tag='☽', font=self.font, text='', line_height=self.line_height, origin=(-.5, .5))</gray></td><td></td>
            </tr>
            <tr>
                <td>.line_numbers<gray> = Text(parent=self.scroll_parent, font=self.font, line_height=line_height, text='0', origin=(.5,.5), x=-.04, color=color.gray, enabled=False)</gray></td><td></td>
            </tr>
            <tr>
                <td>.character_width<gray> = Text.get_width('a', font=self.font)</gray></td><td></td>
            </tr>
            <tr>
                <td>.cursor_parent<gray> = Entity(parent=self.scroll_parent, scale=(self.character_width, -1*Text.size*self.line_height))</gray></td><td></td>
            </tr>
            <tr>
                <td>.cursor<gray> = Entity(name='text_field_cursor', parent=self.cursor_parent, model='cube', color=color.cyan, origin=(-.5, -.5), scale=(.1, 1, 0), enabled=False)</gray></td><td></td>
            </tr>
            <tr>
                <td>.bg<gray> = Entity(name='text_field_bg', parent=self, model='quad', double_sided=True, color=color.dark_gray, origin=(-.5,.5), z=0.005, scale=(120, Text.size*self.max_lines*self.line_height), collider='box', visible=True)</gray></td><td></td>
            </tr>
            <tr>
                <td>.selection<gray> = [Vec2(0,0), Vec2(0,0)]</gray></td><td></td>
            </tr>
            <tr>
                <td>.selection_parent<gray> = Entity(name='text_field_selection_parent', parent=self.cursor_parent, scale=(1,1,0))</gray></td><td></td>
            </tr>
            <tr>
                <td>.register_mouse_input<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.world_space_mouse<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.triple_click_delay<gray> = 0.3</gray></td><td></td>
            </tr>
            <tr>
                <td>.scroll<gray> = 0</gray></td><td></td>
            </tr>
            <tr>
                <td>.scroll_amount<gray> = 2</gray></td><td></td>
            </tr>
            <tr>
                <td>.active<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.highlight_color<gray> = color.hsv(120,1,1,.1)</gray></td><td></td>
            </tr>
            <tr>
                <td>.text<gray> = ''</gray></td><td></td>
            </tr>
            <tr>
                <td>.delimiters<gray> = ' .,!?;:(){}[]&lt&gt\'\"@#$%^&*+=-\\|/`~'</gray></td><td></td>
            </tr>
            <tr>
                <td>.replacements<gray> = dict()</gray></td><td></td>
            </tr>
            <tr>
                <td>.on_undo<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.on_redo<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.on_value_changed<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.shortcuts<gray> = {
        'newline':          ('enter', 'enter hold'),
        'erase':            ('backspace', 'backspace hold'),
        'erase_word':       ('ctrl+backspace', 'ctrl+backspace hold'),
        'delete_line':      ('ctrl+shift+k',),
        'duplicate_line':   ('ctrl+shift+d',),
        'undo':             ('ctrl+z', 'ctrl+z hold'),
        'redo':             ('ctrl+y', 'ctrl+y hold', 'ctrl+shift+z', 'ctrl+shift+z hold'),
        'indent':           ('tab',),
        'dedent':           ('shift+tab',),
        'move_line_down':   ('ctrl+down arrow', 'ctrl+down arrow hold'),
        'move_line_up':     ('ctrl+up arrow', 'ctrl+up arrow hold'),
        'scroll_up':        ('scroll up',),
        'scroll_down':      ('scroll down',),
        'cut':              ('ctrl+x',),
        'copy':             ('ctrl+c',),
        'paste':            ('ctrl+v',),
        'select_all':       ('ctrl+a',),
        'select_word':      ('double click',),
        'select_line':      ('triple click',),
        'scroll_to_bottom': ('shift+alt+e',),
        'move_operations' : {
            'move_left':                ('left arrow', 'left arrow hold', 'shift+left arrow', 'shift+left arrow hold'),
            'move_right':               ('right arrow', 'right arrow hold', 'shift+right arrow', 'shift+right arrow hold'),
            'move_up':                  ('up arrow', 'up arrow hold', 'shift+up arrow', 'shift+up arrow hold'),
            'move_down':                ('down arrow', 'down arrow hold', 'shift+down arrow', 'shift+down arrow hold'),
            'move_to_end_of_word' :     ('ctrl+right arrow', 'ctrl+right arrow hold', 'ctrl+shift+right arrow', 'ctrl+shift+right arrow hold'),
            'move_to_start_of_word' :   ('ctrl+left arrow', 'ctrl+left arrow hold', 'ctrl+shift+left arrow', 'ctrl+shift+left arrow hold'),
        },</gray></td><td></td>
            </tr>
            <tr>
                <td>.middle_click_scroller<gray> = Entity(parent=self, start_y=None, input=middle_click_input, update=middle_click_update, t=0, update_rate=.05)</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.active</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;middle_click_input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;middle_click_update()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;add_text(<gray>s, move_cursor=True, rerender=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;move_line(<gray>line_index, delta, move_cursor=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;erase(<gray>rerender=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;delete_selected()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;get_selected()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;get_mouse_position_unclamped()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;get_mouse_position()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;set_scroll(<gray>value, render=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;move_to_start_of_word()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;move_to_end_of_word()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;scroll_to_bottom(<gray>blank_lines_at_bottom=0</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;text_input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;render()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;select_all()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;draw_selection()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(TextField_example)">copy</button><p id="TextField_example"><purple>from</purple> ursina <purple>import</purple> Ursina, window, Button
app = Ursina(vsync=<yellow>6</yellow><yellow>0</yellow>)


window.color = color.hsv(<yellow>0</yellow>, <yellow>0</yellow>, .<yellow>1</yellow>)
Button.default_color = color._<yellow>2</yellow><yellow>0</yellow>
window.color = color._<yellow>2</yellow><yellow>5</yellow>

te = <purple><b>TextField</b></purple>(max_lines=<yellow>3</yellow><yellow>0</yellow>, <olive>scale</olive>=<yellow>1</yellow>, register_mouse_input = True, <olive>text</olive>=<green>'1234'</green>)
<purple>from</purple> textwrap <purple>import</purple> dedent
te.text = dedent(<green><green>''</green>'
    Lorem ipsum dolor sit amet, consectetur adipiscing elit.
    Aliquam sapien tellus, venenatis sit amet ante et, malesuada porta risus.
    Etiam et mi luctus, viverra urna at, maximus eros. Sed dictum faucibus purus,
    nec rutrum ipsum condimentum in. Mauris iaculis arcu nec justo rutrum euismod.
    Suspendisse dolor tortor, congue id erat sit amet, sollicitudin facilisis velit.
    Aliquam sapien tellus, venenatis sit amet ante et, malesuada porta risus.
    Etiam et mi luctus, viverra urna at, maximus eros. Sed dictum faucibus purus,
    nec rutrum ipsum condimentum in. Mauris iaculis arcu nec justo rutrum euismod.
    Suspendisse dolor tortor, congue id erat sit amet, sollicitudin facilisis velit.
    <green>''</green>'</green>*<yellow>3</yellow><yellow>0</yellow>
    )[<yellow>1</yellow>:]
te.render()

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'3'</green>:
        te.input(<green>'scroll down'</green>)


app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Cursor">
        <h1>Cursor<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/cursor.py"><gray>ursina/prefabs/cursor</gray></a><br><br>
        <div class="params">Cursor(**kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.parent<gray> = camera.ui</gray></td><td></td>
            </tr>
            <tr>
                <td>.texture<gray> = 'cursor'</gray></td><td></td>
            </tr>
            <tr>
                <td>.model<gray> = 'quad'</gray></td><td></td>
            </tr>
            <tr>
                <td>.color<gray> = color.light_gray</gray></td><td></td>
            </tr>
            <tr>
                <td>.render_queue<gray> = 1</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Cursor_example)">copy</button><p id="Cursor_example"><purple>from</purple> ursina <purple>import</purple> Ursina, Button, scene, Panel, Mesh
app = Ursina()
Button(<green>'button'</green>).fit_to_text()
camera.orthographic = True
camera.fov = <yellow>1</yellow><yellow>0</yellow><yellow>0</yellow>
cursor =  <purple><b>Cursor</b></purple>(<olive>model</olive>=Mesh(<olive>vertices</olive>=[(-.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>),(.<yellow>5</yellow>,<yellow>0</yellow>,<yellow>0</yellow>),(<yellow>0</yellow>,-.<yellow>5</yellow>,<yellow>0</yellow>),(<yellow>0</yellow>,.<yellow>5</yellow>,<yellow>0</yellow>)], <olive>triangles</olive>=[(<yellow>0</yellow>,<yellow>1</yellow>),(<yellow>2</yellow>,<yellow>3</yellow>)], <olive>mode</olive>=<green>'line'</green>, <olive>thickness</olive>=<yellow>2</yellow>), <olive>scale</olive>=.<yellow>0</yellow><yellow>2</yellow>)
mouse.visible = False
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="InputField">
        <h1>InputField<a style="color: gray; font-weight:normal;" href="#Button">(Button)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/input_field.py"><gray>ursina/prefabs/input_field</gray></a><br><br>
        <div class="params">InputField(default_value='', label='', max_lines=1, character_limit=24, text='', active=False, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.default_value<gray> = default_value</gray></td><td></td>
            </tr>
            <tr>
                <td>.limit_content_to<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.hide_content<gray> = False   </gray></td><td><span>if set to True, will display content as '*'. can also be set to character instead of True.</span></td>
            </tr>
            <tr>
                <td>.next_field<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.submit_on<gray> = []   </gray></td><td><span>for example: self.submit_on</span></td>
            </tr>
            <tr>
                <td>.on_submit<gray> = None   </gray></td><td><span>function to be called when you press self.submit_on.</span></td>
            </tr>
            <tr>
                <td>.on_value_changed<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.text_field<gray> = TextField(world_parent=self, x=-.45, y=.25, z=-.1, max_lines=max_lines, character_limit=character_limit, text=text, register_mouse_input=True)</gray></td><td></td>
            </tr>
            <tr>
                <td>.active<gray> = active</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.text</td><td><span></span></td>
            </tr>
            <tr>
                <td>.text_color</td><td><span></span></td>
            </tr>
            <tr>
                <td>.active</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;render()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(InputField_example)">copy</button><p id="InputField_example">app = Ursina()
gradient = <olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>, <olive>texture</olive>=<green>'vertical_gradient'</green>, <olive>parent</olive>=camera.ui, <olive>scale</olive>=(camera.aspect_ratio,<yellow>1</yellow>), <olive>color</olive>=color.hsv(<yellow>2</yellow><yellow>4</yellow><yellow>0</yellow>,.<yellow>6</yellow>,.<yellow>1</yellow>,.<yellow>7</yellow><yellow>5</yellow>))

username_field = <purple><b>InputField</b></purple>(<olive>y</olive>=-.<yellow>1</yellow><yellow>2</yellow>, limit_content_to=<green>'0123456789'</green>, default_value=<green>'11'</green>, active=True)
username_field.text = <green>'0929468098'</green>
password_field = <purple><b>InputField</b></purple>(<olive>y</olive>=-.<yellow>1</yellow><yellow>8</yellow>, hide_content=True)
username_field.next_field = password_field

<purple>def</purple> submit():
    <blue>print</blue>(<green>'ursername:'</green>, username_field.text)
    <blue>print</blue>(<green>'password:'</green>,  password_field.text)

Button(<olive>text</olive>=<green>'Login'</green>, <olive>scale</olive>=.<yellow>1</yellow>, <olive>color</olive>=color.cyan.tint(-.<yellow>4</yellow>), <olive>y</olive>=-.<yellow>2</yellow><yellow>6</yellow>, <olive>on_click</olive>=submit).fit_to_text()
username_field.on_value_changed = submit
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="ContentTypes">
        <h1>ContentTypes</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/input_field.py"><gray>ursina/prefabs/input_field</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>ContentTypes.int = '0123456789'</td><td></td>
            </tr>
            <tr>
                <td>ContentTypes.float = int + '.,'</td><td></td>
            </tr>
            <tr>
                <td>ContentTypes.int_math = int + '+-*/'</td><td></td>
            </tr>
            <tr>
                <td>ContentTypes.math = float + '+-*/'</td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(ContentTypes_example)">copy</button><p id="ContentTypes_example">app = Ursina()
gradient = <olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>, <olive>texture</olive>=<green>'vertical_gradient'</green>, <olive>parent</olive>=camera.ui, <olive>scale</olive>=(camera.aspect_ratio,<yellow>1</yellow>), <olive>color</olive>=color.hsv(<yellow>2</yellow><yellow>4</yellow><yellow>0</yellow>,.<yellow>6</yellow>,.<yellow>1</yellow>,.<yellow>7</yellow><yellow>5</yellow>))

username_field = InputField(<olive>y</olive>=-.<yellow>1</yellow><yellow>2</yellow>, limit_content_to=<green>'0123456789'</green>, default_value=<green>'11'</green>, active=True)
username_field.text = <green>'0929468098'</green>
password_field = InputField(<olive>y</olive>=-.<yellow>1</yellow><yellow>8</yellow>, hide_content=True)
username_field.next_field = password_field

<purple>def</purple> submit():
    <blue>print</blue>(<green>'ursername:'</green>, username_field.text)
    <blue>print</blue>(<green>'password:'</green>,  password_field.text)

Button(<olive>text</olive>=<green>'Login'</green>, <olive>scale</olive>=.<yellow>1</yellow>, <olive>color</olive>=color.cyan.tint(-.<yellow>4</yellow>), <olive>y</olive>=-.<yellow>2</yellow><yellow>6</yellow>, <olive>on_click</olive>=submit).fit_to_text()
username_field.on_value_changed = submit
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="ButtonList">
        <h1>ButtonList<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/button_list.py"><gray>ursina/prefabs/button_list</gray></a><br><br>
        <div class="params">ButtonList(button_dict, button_height=1.1, width=.5, popup=False, color=Button.default_color, highlight_color=color.white33, selected_color=color.azure, font=Text.default_font, clear_selected_on_enable=True, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.clear_selected_on_enable<gray> = clear_selected_on_enable</gray></td><td></td>
            </tr>
            <tr>
                <td>.button_height<gray> = button_height</gray></td><td></td>
            </tr>
            <tr>
                <td>.width<gray> = width</gray></td><td></td>
            </tr>
            <tr>
                <td>.text_entity<gray> = Text(parent=self, font=font, origin=(-.5,.5), text='empty', world_scale=20, z=-.1, x=.01, y=-(button_height*.25*Text.size), line_height=button_height)</gray></td><td></td>
            </tr>
            <tr>
                <td>.bg<gray> = Entity(parent=self, model='quad', origin=(-.5,.5), scale=width, color=color, collider='box')</gray></td><td></td>
            </tr>
            <tr>
                <td>.highlight<gray> = Entity(parent=self.bg, model='quad', color=highlight_color, scale=(1,self.button_height), origin=(-.5,.5), z=-.01, add_to_scene_entities=False)</gray></td><td></td>
            </tr>
            <tr>
                <td>.selection_marker<gray> = Entity(parent=self.bg, model='quad', color=selected_color, scale=(1,self.button_height), origin=(-.5,.5), z=-.02, enabled=False, add_to_scene_entities=False)</gray></td><td></td>
            </tr>
            <tr>
                <td>.button_dict<gray> = button_dict</gray></td><td></td>
            </tr>
            <tr>
                <td>.popup<gray> = popup</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.button_dict</td><td><span></span></td>
            </tr>
            <tr>
                <td>.selected</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_disable()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_enable()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(ButtonList_example)">copy</button><p id="ButtonList_example"><purple>from</purple> ursina <purple>import</purple> Ursina, Func
app = Ursina()

default = Func(print, <green>'not yet implemented'</green>)

<purple>def</purple> test(a=<yellow>1</yellow>, b=<yellow>2</yellow>):
    <blue>print</blue>(<green>'------:'</green>, a, b)

button_dict = {}
<purple>for</purple> i in <blue>range</blue>(<yellow>6</yellow>, <yellow>2</yellow><yellow>0</yellow>):
    button_dict[f<green>'button {i}'</green>] = Func(print, i)

bl = <purple><b>ButtonList</b></purple>(button_dict, font=<green>'VeraMono.ttf'</green>, button_height=<yellow>1</yellow>.<yellow>5</yellow>, popup=<yellow>0</yellow>, clear_selected_on_enable=False)
<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'space'</green>:
        bl.button_dict = {
            <green>'one'</green> :     None,
            <green>'two'</green> :     default,
            <green>'tree'</green> :    Func(test, <yellow>3</yellow>, <yellow>4</yellow>),
            <green>'four'</green> :    Func(test, b=<yellow>3</yellow>, a=<yellow>4</yellow>),
        }
    <purple>if</purple> key == <green>'o'</green>:
        bl.enabled = True

bl.selected = <green>'button 7'</green>

bl.button_dict = {}

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="ButtonGroup">
        <h1>ButtonGroup<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/button_group.py"><gray>ursina/prefabs/button_group</gray></a><br><br>
        <div class="params">ButtonGroup(options, default='', min_selection=1, max_selection=1, origin=(-.5,.5,0), spacing=(0.025,0,0), label='', **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.deselected_color<gray> = Button.default_color</gray></td><td></td>
            </tr>
            <tr>
                <td>.selected_color<gray> = ButtonGroup.default_selected_color</gray></td><td></td>
            </tr>
            <tr>
                <td>.min_selection<gray> = min_selection</gray></td><td></td>
            </tr>
            <tr>
                <td>.max_selection<gray> = max(min_selection, max_selection)</gray></td><td></td>
            </tr>
            <tr>
                <td>.origin<gray> = origin</gray></td><td></td>
            </tr>
            <tr>
                <td>.spacing<gray> = spacing</gray></td><td></td>
            </tr>
            <tr>
                <td>.buttons<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.selected<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.options<gray> = options</gray></td><td></td>
            </tr>
            <tr>
                <td>.parent<gray> = camera.ui</gray></td><td></td>
            </tr>
            <tr>
                <td>.scale<gray> = Text.size * 2</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.options</td><td><span></span></td>
            </tr>
            <tr>
                <td>.value</td><td><span></span></td>
            </tr>
            <tr>
                <td>.label</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;layout()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;select(<gray>b</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_value_changed()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(ButtonGroup_example)">copy</button><p id="ButtonGroup_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()

center = <olive>Entity</olive>(<olive>parent</olive>=camera.ui, <olive>model</olive>=<green>'circle'</green>, <olive>scale</olive>=.<yellow>0</yellow><yellow>0</yellow><yellow>5</yellow>, <olive>color</olive>=color.red, <olive>z</olive>=-<yellow>1</yellow>)
gender_selection = <purple><b>ButtonGroup</b></purple>((<green>'man'</green>, <green>'woman'</green>, <green>'other'</green>), <olive>origin</olive>=(-.<yellow>5</yellow>,<yellow>0</yellow>), label=<green>'choose gender:'</green>)

<purple>def</purple> on_value_changed():
    <blue>print</blue>(<green>'set gender:'</green>, gender_selection.value)
gender_selection.on_value_changed = on_value_changed


window.color = color._<yellow>3</yellow><yellow>2</yellow></p>
</div>

</div>
<br>
    <div class="class_box" id="WindowPanel">
        <h1>WindowPanel<a style="color: gray; font-weight:normal;" href="#Draggable">(Draggable)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/window_panel.py"><gray>ursina/prefabs/window_panel</gray></a><br><br>
        <div class="params">WindowPanel(title='', content=[], **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.content<gray> = content</gray></td><td></td>
            </tr>
            <tr>
                <td>.popup<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.panel<gray> = Entity(parent=self, model='quad', origin=(0,.5), z=.1, color=self.color.tint(.1), collider='box')</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;layout()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(WindowPanel_example)">copy</button><p id="WindowPanel_example"><green><green>''</green>'
WindowPanel is an easy way to create UI. It will automatically layout the content.
<green>''</green>'</green>
<purple>from</purple> ursina <purple>import</purple> Ursina, ButtonGroup
app = Ursina()
wp = <purple><b>WindowPanel</b></purple>(
    title=<green>'Custom Window'</green>,
    content=(
        Text(<green>'Name:'</green>),
        InputField(name=<green>'name_field'</green>),
        Button(<olive>text</olive>=<green>'Submit'</green>, <olive>color</olive>=color.azure),
        Slider(),
        Slider(),
        ButtonGroup((<green>'test'</green>, <green>'eslk'</green>, <green>'skffk'</green>))
        ),
    popup=True
    )
wp.y = wp.panel.scale_y / 2 * wp.scale_y    <gray># center the window panel</gray>
wp.layout()

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'space'</green>:
        wp.enabled = True

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Space">
        <h1>Space</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/window_panel.py"><gray>ursina/prefabs/window_panel</gray></a><br><br>
        <div class="params">Space(height=1)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.height<gray> = height</gray></td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Space_example)">copy</button><p id="Space_example"><green><green>''</green>'
WindowPanel is an easy way to create UI. It will automatically layout the content.
<green>''</green>'</green>
<purple>from</purple> ursina <purple>import</purple> Ursina, ButtonGroup
app = Ursina()
wp = WindowPanel(
    title=<green>'Custom Window'</green>,
    content=(
        Text(<green>'Name:'</green>),
        InputField(name=<green>'name_field'</green>),
        Button(<olive>text</olive>=<green>'Submit'</green>, <olive>color</olive>=color.azure),
        Slider(),
        Slider(),
        ButtonGroup((<green>'test'</green>, <green>'eslk'</green>, <green>'skffk'</green>))
        ),
    popup=True
    )
wp.y = wp.panel.scale_y / 2 * wp.scale_y    <gray># center the window panel</gray>
wp.layout()

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'space'</green>:
        wp.enabled = True

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="FileBrowser">
        <h1>FileBrowser<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/file_browser.py"><gray>ursina/prefabs/file_browser</gray></a><br><br>
        <div class="params">FileBrowser(file_button_class=FileButton, selection_limit=1, start_path=None, file_types:list=None, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.file_types<gray> = file_types if file_types else ['.*', ]</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.scroll</td><td><span></span></td>
            </tr>
            <tr>
                <td>.path</td><td><span></span></td>
            </tr>
            <tr>
                <td>.selection</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_enable()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;close()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;folder_up()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;open(<gray>path=None</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(FileBrowser_example)">copy</button><p id="FileBrowser_example">app = Ursina()

fb = <purple><b>FileBrowser</b></purple>(file_types=(<green>'.*'</green>), <olive>enabled</olive>=False)

<purple>def</purple> on_submit(paths):
    <blue>print</blue>(<green>'--------'</green>, paths)
    <purple>for</purple> p in paths:
        <blue>print</blue>(<green>'---'</green>, p)

fb.on_submit = on_submit

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'tab'</green>:
        fb.enabled = <purple>not</purple> fb.enabled


app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="FileButton">
        <h1>FileButton<a style="color: gray; font-weight:normal;" href="#Button">(Button)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/file_browser.py"><gray>ursina/prefabs/file_browser</gray></a><br><br>
        <div class="params">FileButton(load_menu, path, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.load_menu<gray> = load_menu</gray></td><td></td>
            </tr>
            <tr>
                <td>.path<gray> = path</gray></td><td></td>
            </tr>
            <tr>
                <td>.original_color<gray> = self.color</gray></td><td></td>
            </tr>
            <tr>
                <td>.selected<gray> = False</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.selected</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;on_click()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_double_click()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(FileButton_example)">copy</button><p id="FileButton_example">app = Ursina()

fb = FileBrowser(file_types=(<green>'.*'</green>), <olive>enabled</olive>=False)

<purple>def</purple> on_submit(paths):
    <blue>print</blue>(<green>'--------'</green>, paths)
    <purple>for</purple> p in paths:
        <blue>print</blue>(<green>'---'</green>, p)

fb.on_submit = on_submit

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'tab'</green>:
        fb.enabled = <purple>not</purple> fb.enabled


app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="FileBrowserSave">
        <h1>FileBrowserSave<a style="color: gray; font-weight:normal;" href="#FileBrowser">(FileBrowser)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/file_browser_save.py"><gray>ursina/prefabs/file_browser_save</gray></a><br><br>
        <div class="params">FileBrowserSave(**kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.save_button<gray> = self.open_button</gray></td><td></td>
            </tr>
            <tr>
                <td>.file_name_field<gray> = InputField(parent=self, scale_x=.75, scale_y=self.save_button.scale_y, y=self.save_button.y)</gray></td><td></td>
            </tr>
            <tr>
                <td>.file_type<gray> = '' </gray></td><td><span>to save as</span></td>
            </tr>
            <tr>
                <td>.last_saved_file<gray> = None     </gray></td><td><span>gets set when you save a file</span></td>
            </tr>
            <tr>
                <td>.overwrite_prompt<gray> = WindowPanel(
        content=(
            Text('Overwrite?'),
            Button('Yes', color=color.azure, on_click=self._save),
            Button('Cancel')
        ), z=-1, popup=True, enabled=False)</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.file_type</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;on_enable()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_disable()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_submit(<gray>path</gray>)</td> <td><span>implement .on_submit to handle saving</span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(FileBrowserSave_example)">copy</button><p id="FileBrowserSave_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina.prefabs.file_browser_save <purple>import</purple> FileBrowserSave

app = Ursina()
wp = <purple><b>FileBrowserSave</b></purple>(file_type = <green>'.*'</green>)


<purple>import</purple> json
save_data = {<green>'level'</green>: <yellow>4</yellow>, <green>'name'</green>:<green>'Link'</green>}
wp.data = json.dumps(save_data)

wp.enabled = False
<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'tab'</green>:
        wp.enabled = <purple>not</purple> wp.enabled


app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="DropdownMenu">
        <h1>DropdownMenu<a style="color: gray; font-weight:normal;" href="#DropdownMenuButton">(DropdownMenuButton)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/dropdown_menu.py"><gray>ursina/prefabs/dropdown_menu</gray></a><br><br>
        <div class="params">DropdownMenu(text='', buttons:list=None, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.position<gray> = window.top_left</gray></td><td></td>
            </tr>
            <tr>
                <td>.buttons<gray> = buttons</gray></td><td></td>
            </tr>
            <tr>
                <td>.arrow_symbol<gray> = Text(world_parent=self, text='&gt', origin=(.5,.5), position=(.95, 0), color=color.gray)</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;open()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;close()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;on_mouse_enter()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(DropdownMenu_example)">copy</button><p id="DropdownMenu_example"><purple>from</purple> ursina.prefabs.dropdown_menu <purple>import</purple> DropdownMenu, DropdownMenuButton

app = Ursina()
<purple><b>DropdownMenu</b></purple>(<green>'File'</green>, buttons=(
    DropdownMenuButton(<green>'New'</green>),
    DropdownMenuButton(<green>'Open'</green>),
    <purple><b>DropdownMenu</b></purple>(<green>'Reopen Project'</green>, buttons=(
        DropdownMenuButton(<green>'Project 1'</green>),
        DropdownMenuButton(<green>'Project 2'</green>),
        )),
    DropdownMenuButton(<green>'Save'</green>),
    <purple><b>DropdownMenu</b></purple>(<green>'Options'</green>, buttons=(
        DropdownMenuButton(<green>'Option a'</green>),
        DropdownMenuButton(<green>'Option b'</green>),
        )),
    DropdownMenuButton(<green>'Exit'</green>),
    ))

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="DropdownMenuButton">
        <h1>DropdownMenuButton<a style="color: gray; font-weight:normal;" href="#Button">(Button)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/dropdown_menu.py"><gray>ursina/prefabs/dropdown_menu</gray></a><br><br>
        <div class="params">DropdownMenuButton(text='', **kwargs)</div><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(DropdownMenuButton_example)">copy</button><p id="DropdownMenuButton_example"><purple>from</purple> ursina.prefabs.dropdown_menu <purple>import</purple> DropdownMenu, DropdownMenuButton

app = Ursina()
DropdownMenu(<green>'File'</green>, buttons=(
    <purple><b>DropdownMenuButton</b></purple>(<green>'New'</green>),
    <purple><b>DropdownMenuButton</b></purple>(<green>'Open'</green>),
    DropdownMenu(<green>'Reopen Project'</green>, buttons=(
        <purple><b>DropdownMenuButton</b></purple>(<green>'Project 1'</green>),
        <purple><b>DropdownMenuButton</b></purple>(<green>'Project 2'</green>),
        )),
    <purple><b>DropdownMenuButton</b></purple>(<green>'Save'</green>),
    DropdownMenu(<green>'Options'</green>, buttons=(
        <purple><b>DropdownMenuButton</b></purple>(<green>'Option a'</green>),
        <purple><b>DropdownMenuButton</b></purple>(<green>'Option b'</green>),
        )),
    <purple><b>DropdownMenuButton</b></purple>(<green>'Exit'</green>),
    ))

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="RadialMenu">
        <h1>RadialMenu<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/radial_menu.py"><gray>ursina/prefabs/radial_menu</gray></a><br><br>
        <div class="params">RadialMenu(buttons=list(), **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.parent<gray> = camera.ui</gray></td><td></td>
            </tr>
            <tr>
                <td>.buttons<gray> = buttons</gray></td><td></td>
            </tr>
            <tr>
                <td>.open_at_cursor<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.open_duration<gray> = .1</gray></td><td></td>
            </tr>
            <tr>
                <td>.bg<gray> = Panel(parent=self, model='quad', z=99, scale=999, collider='box', color=color.hsv(0,0,0,.1), enabled=False)</gray></td><td></td>
            </tr>
            <tr>
                <td>.z<gray> = -99</gray></td><td></td>
            </tr>
            <tr>
                <td>.scale<gray> = .075</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;on_enable()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(RadialMenu_example)">copy</button><p id="RadialMenu_example">app = Ursina()

rm = <purple><b>RadialMenu</b></purple>(
    buttons = (
        RadialMenuButton(<olive>text</olive>=<green>'1'</green>),
        RadialMenuButton(<olive>text</olive>=<green>'2'</green>),
        RadialMenuButton(<olive>text</olive>=<green>'3'</green>),
        RadialMenuButton(<olive>text</olive>=<green>'4'</green>),
        RadialMenuButton(<olive>text</olive>=<green>'5'</green>, <olive>scale</olive>=.<yellow>5</yellow>),
        RadialMenuButton(<olive>text</olive>=<green>'6'</green>, <olive>color</olive>=color.red),
        ),
    enabled = False
    )
RadialMenuButton(<olive>text</olive>=<green>'6'</green>, <olive>color</olive>=color.red,x =-.<yellow>5</yellow>, <olive>scale</olive>=.<yellow>0</yellow><yellow>6</yellow>),
<purple>def</purple> enable_radial_menu():
    rm.enabled = True
cube = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.orange, <olive>highlight_color</olive>=color.azure, <olive>on_click</olive>=enable_radial_menu)
EditorCamera()
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="RadialMenuButton">
        <h1>RadialMenuButton<a style="color: gray; font-weight:normal;" href="#Button">(Button)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/radial_menu.py"><gray>ursina/prefabs/radial_menu</gray></a><br><br>
        <div class="params">RadialMenuButton(**kwargs)</div><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(RadialMenuButton_example)">copy</button><p id="RadialMenuButton_example">app = Ursina()

rm = RadialMenu(
    buttons = (
        <purple><b>RadialMenuButton</b></purple>(<olive>text</olive>=<green>'1'</green>),
        <purple><b>RadialMenuButton</b></purple>(<olive>text</olive>=<green>'2'</green>),
        <purple><b>RadialMenuButton</b></purple>(<olive>text</olive>=<green>'3'</green>),
        <purple><b>RadialMenuButton</b></purple>(<olive>text</olive>=<green>'4'</green>),
        <purple><b>RadialMenuButton</b></purple>(<olive>text</olive>=<green>'5'</green>, <olive>scale</olive>=.<yellow>5</yellow>),
        <purple><b>RadialMenuButton</b></purple>(<olive>text</olive>=<green>'6'</green>, <olive>color</olive>=color.red),
        ),
    enabled = False
    )
<purple><b>RadialMenuButton</b></purple>(<olive>text</olive>=<green>'6'</green>, <olive>color</olive>=color.red,x =-.<yellow>5</yellow>, <olive>scale</olive>=.<yellow>0</yellow><yellow>6</yellow>),
<purple>def</purple> enable_radial_menu():
    rm.enabled = True
cube = Button(<olive>parent</olive>=scene, <olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.orange, <olive>highlight_color</olive>=color.azure, <olive>on_click</olive>=enable_radial_menu)
EditorCamera()
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="HealthBar">
        <h1>HealthBar<a style="color: gray; font-weight:normal;" href="#Button">(Button)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/health_bar.py"><gray>ursina/prefabs/health_bar</gray></a><br><br>
        <div class="params">HealthBar(max_value=100, value=Default, roundness=.25, bar_color=color.red.tint(-.2), highlight_color=color.black66, animation_duration=.1, show_text=True, show_lines=False, text_size=.7, scale=(.5,.025), origin=(-.5,.5), name='health_bar', **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.bar<gray> = Entity(parent=self, model=Quad(radius=roundness), origin=origin, z=-.005, color=bar_color, highlight_color=highlight_color, ignore=True)</gray></td><td></td>
            </tr>
            <tr>
                <td>.lines<gray> = Entity(parent=self.bar, y=-1, color=color.black33, ignore=True, enabled=show_lines, z=-.05)</gray></td><td></td>
            </tr>
            <tr>
                <td>.max_value<gray> = max_value</gray></td><td></td>
            </tr>
            <tr>
                <td>.clamp<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.roundness<gray> = roundness</gray></td><td></td>
            </tr>
            <tr>
                <td>.animation_duration<gray> = animation_duration</gray></td><td></td>
            </tr>
            <tr>
                <td>.show_lines<gray> = show_lines</gray></td><td></td>
            </tr>
            <tr>
                <td>.show_text<gray> = show_text</gray></td><td></td>
            </tr>
            <tr>
                <td>.value<gray> = self.max_value if value == Default else value</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.value</td><td><span></span></td>
            </tr>
            <tr>
                <td>.show_text</td><td><span></span></td>
            </tr>
            <tr>
                <td>.show_lines</td><td><span></span></td>
            </tr>
            <tr>
                <td>.bar_color</td><td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(HealthBar_example)">copy</button><p id="HealthBar_example">app = Ursina()

health_bar_<yellow>1</yellow> = <purple><b>HealthBar</b></purple>(bar_<olive>color</olive>=color.lime.tint(-.<yellow>2</yellow><yellow>5</yellow>), roundness=.<yellow>5</yellow>, max_value=<yellow>1</yellow><yellow>0</yellow><yellow>0</yellow>, value=<yellow>5</yellow><yellow>0</yellow>, <olive>scale</olive>=(.<yellow>5</yellow>,.<yellow>1</yellow>))
<blue>print</blue>(health_bar_<yellow>1</yellow>.text_entity.enabled, health_bar_<yellow>1</yellow>.text_entity.text)

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'+'</green> or key == <green>'+ hold'</green>:
        health_bar_<yellow>1</yellow>.value += <yellow>1</yellow><yellow>0</yellow>
    <purple>if</purple> key == <green>'-'</green> or key == <green>'- hold'</green>:
        health_bar_<yellow>1</yellow>.value -= <yellow>1</yellow><yellow>0</yellow>
        <blue>print</blue>(<green>'ow'</green>)
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="ColorPicker">
        <h1>ColorPicker<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/color_picker.py"><gray>ursina/prefabs/color_picker</gray></a><br><br>
        <div class="params">ColorPicker(dynamic=True, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.bg<gray> = Entity(parent=self, z=.01, model=Quad(aspect=.5/.2), scale=[.5,.225], origin=[0,.5], color=color.black66)</gray></td><td></td>
            </tr>
            <tr>
                <td>.h_slider<gray> = Slider(parent=self, max=360, step=1, dynamic=dynamic, on_value_changed=self._calculate_color)</gray></td><td></td>
            </tr>
            <tr>
                <td>.s_slider<gray> = Slider(parent=self, max=100, step=1, dynamic=dynamic, on_value_changed=self._calculate_color)</gray></td><td></td>
            </tr>
            <tr>
                <td>.v_slider<gray> = Slider(parent=self, max=100, step=1, dynamic=dynamic, on_value_changed=self._calculate_color)</gray></td><td></td>
            </tr>
            <tr>
                <td>.a_slider<gray> = Slider(parent=self, max=100, default=100, step=1, dynamic=dynamic, on_value_changed=self._calculate_color)</gray></td><td></td>
            </tr>
            <tr>
                <td>.on_value_changed<gray> = None    </gray></td><td><span>assign a function here</span></td>
            </tr>
            <tr>
                <td>.preview<gray> = Button(parent=self, scale=(.5*.84,.05), origin=[0,.5], y=slider.y-.02, color=color.white)</gray></td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(ColorPicker_example)">copy</button><p id="ColorPicker_example"><purple>from</purple> ursina <purple>import</purple> Ursina
app = Ursina()
<purple><b>ColorPicker</b></purple>()

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="HotReloader">
        <h1>HotReloader<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/hot_reloader.py"><gray>ursina/prefabs/hot_reloader</gray></a><br><br>
        <div class="params">HotReloader(path=__file__, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.path<gray> = path</gray></td><td></td>
            </tr>
            <tr>
                <td>.path<gray> = Path(self.path)</gray></td><td></td>
            </tr>
            <tr>
                <td>.hotreload<gray> = False   </gray></td><td><span>toggle with f9</span></td>
            </tr>
            <tr>
                <td>.hotkeys<gray> = {
        'ctrl+r' : self.reload_code,
        'f5'     : self.reload_code,
        'f6'     : self.reload_textures,
        'f7'     : self.reload_models,
        'f8'     : self.reload_shaders,
        'f9'     : self.toggle_hotreloading,
        }
        </gray></td><td></td>
            </tr>
            <tr>
                <td>.hotreload_window_settings<gray> = dict(size=(window.size[0]/2,window.size[1]/2), always_on_top=True, position=(window.fullscreen_size[0]-window.size[0]/22, 0))</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;get_source_code()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;toggle_hotreloading()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;reload_code(<gray>reset_camera=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;reload_textures()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;reload_models()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;reload_shaders()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(HotReloader_example)">copy</button><p id="HotReloader_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()

<green><green>''</green>'
By default you can press F5 to reload the starting script, F6 to reimport textures and F7 to reload models.
<green>''</green>'</green></p>
</div>

</div>
<br>
    <div class="class_box" id="GridEditor">
        <h1>GridEditor<a style="color: gray; font-weight:normal;" href="#Entity">(Entity)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/grid_editor.py"><gray>ursina/prefabs/grid_editor</gray></a><br><br>
        <div class="params">GridEditor(size=(32,32), palette=(' ', '#', '|', 'o'), canvas_color=color.white, edit_mode=True, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.w, self.h<gray> = int(size[0]), int(size[1])</gray></td><td></td>
            </tr>
            <tr>
                <td>.canvas<gray> = Entity(parent=self, model='quad', origin=(-.5,-.5), shader=unlit_shader, scale=(self.w/self.h, 1), color=canvas_color)</gray></td><td></td>
            </tr>
            <tr>
                <td>.canvas_collider<gray> = Entity(parent=self.canvas, model='wireframe_quad', origin=self.canvas.origin, color=color.blue, scale=2, position=(-.5,-.5), collider='box', visible=False)</gray></td><td></td>
            </tr>
            <tr>
                <td>.brush_size<gray> = 1</gray></td><td></td>
            </tr>
            <tr>
                <td>.auto_render<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.cursor<gray> = Entity(parent=self.canvas, model=Quad(segments=0, mode='line', thickness=2), origin=(-.5,-.5), scale=(1/self.w, 1/self.h), color=color.hsv(120,1,1,.5), z=-.2, shader=unlit_shader)</gray></td><td></td>
            </tr>
            <tr>
                <td>.selected_char<gray> = palette[1]</gray></td><td></td>
            </tr>
            <tr>
                <td>.palette<gray> = palette</gray></td><td></td>
            </tr>
            <tr>
                <td>.start_pos<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.prev_draw<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.lock_axis<gray> = None</gray></td><td></td>
            </tr>
            <tr>
                <td>.outline<gray> = Entity(parent=self.canvas, model=Quad(segments=0, mode='line', thickness=2), color=color.cyan, z=.01, origin=(-.5,-.5))</gray></td><td></td>
            </tr>
            <tr>
                <td>.rect_selection<gray> = [Vec2(0,0), Vec2(0,0)]</gray></td><td></td>
            </tr>
            <tr>
                <td>.selection_renderer<gray> = Entity(parent=self.canvas, model=Mesh(mode='line', thickness=2), color=color.lime, alpha=.5, z=-.01, origin=(-.5,-.5), scale=(1/self.w,1/self.h))</gray></td><td></td>
            </tr>
            <tr>
                <td>.rect_tool<gray> = Entity(parent=self.canvas, model=Quad(0, mode='line', thickness=2), color=color.lime, z=-.01, origin=(-.5,-.5), start=Vec2(0,0), end=Vec2(0,0))</gray></td><td></td>
            </tr>
            <tr>
                <td>.selection_matrix<gray> = [[0 for y in range(self.h)] for x in range(self.w)]</gray></td><td></td>
            </tr>
            <tr>
                <td>.temp_paste_layer<gray> = Entity(parent=self.cursor, model='quad', origin=(-.5,-.5), z=-.02, enabled=False)</gray></td><td></td>
            </tr>
            <tr>
                <td>.is_in_paste_mode<gray> = False</gray></td><td></td>
            </tr>
            <tr>
                <td>.undo_stack<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.undo_index<gray> = 0</gray></td><td></td>
            </tr>
            <tr>
                <td>.help_icon<gray> = Button(parent=self.canvas, scale=.025, model='circle', origin=(-.5,-.5), position=(-.0,1.005,-1), text='?', target_scale=.025)</gray></td><td></td>
            </tr>
            <tr>
                <td>.edit_mode<gray> = edit_mode</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.palette</td><td><span></span></td>
            </tr>
            <tr>
                <td>.edit_mode</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;get_cursor_position()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;draw(<gray>x, y</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;record_undo()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;floodfill(<gray>matrix, x, y, first=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;copy()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;enter_paste_mode()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;exit_paste_mode(<gray>discard=False</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;clear_selection()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;render_selection()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(GridEditor_example)">copy</button><p id="GridEditor_example">app = Ursina(borderless=False)
<green><green>''</green>'
pixel editor example, it's basically a drawing tool.
can be useful for level editors and such
here we create a new texture, but can also give it an existing texture to modify.
<green>''</green>'</green>
<purple>from</purple> PIL <purple>import</purple> Image
t = Texture(Image.new(<olive>mode</olive>=<green>'RGBA'</green>, size=(<yellow>3</yellow><yellow>2</yellow>,<yellow>3</yellow><yellow>2</yellow>), <olive>color</olive>=(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>,<yellow>1</yellow>)))
<purple>from</purple> ursina.prefabs.grid_editor <purple>import</purple> PixelEditor
editor = PixelEditor(<olive>parent</olive>=scene, <olive>texture</olive>=load_texture(<green>'brick'</green>), <olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>)

camera.orthographic = True
camera.fov = <yellow>1</yellow><yellow>5</yellow>
EditorCamera(rotation_speed=<yellow>0</yellow>)

<purple>from</purple> ursina.prefabs.grid_editor <purple>import</purple> ASCIIEditor
ASCIIEditor(x=<yellow>0</yellow>, <olive>scale</olive>=.<yellow>1</yellow>)

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="PixelEditor">
        <h1>PixelEditor<a style="color: gray; font-weight:normal;" href="#GridEditor">(GridEditor)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/grid_editor.py"><gray>ursina/prefabs/grid_editor</gray></a><br><br>
        <div class="params">PixelEditor(texture, palette=(color.black, color.white, color.light_gray, color.gray, color.red, color.orange, color.yellow, color.lime, color.green, color.turquoise, color.cyan, color.azure, color.blue, color.violet, color.magenta, color.pink), **kwargs)</div><br>
        <table> <!-- attributes -->
        </table><br>
        <div><gray>properties:</gray></div>
        <table>
            <tr>
                <td>.texture</td><td><span></span></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;set_texture(<gray>texture, render=True, clear_undo_stack=True</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;draw(<gray>x, y</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;render()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;save()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(PixelEditor_example)">copy</button><p id="PixelEditor_example">app = Ursina(borderless=False)
<green><green>''</green>'
pixel editor example, it's basically a drawing tool.
can be useful for level editors and such
here we create a new texture, but can also give it an existing texture to modify.
<green>''</green>'</green>
<purple>from</purple> PIL <purple>import</purple> Image
t = Texture(Image.new(<olive>mode</olive>=<green>'RGBA'</green>, size=(<yellow>3</yellow><yellow>2</yellow>,<yellow>3</yellow><yellow>2</yellow>), <olive>color</olive>=(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>,<yellow>1</yellow>)))
<purple>from</purple> ursina.prefabs.grid_editor <purple>import</purple> PixelEditor
editor = <purple><b>PixelEditor</b></purple>(<olive>parent</olive>=scene, <olive>texture</olive>=load_texture(<green>'brick'</green>), <olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>)

camera.orthographic = True
camera.fov = <yellow>1</yellow><yellow>5</yellow>
EditorCamera(rotation_speed=<yellow>0</yellow>)

<purple>from</purple> ursina.prefabs.grid_editor <purple>import</purple> ASCIIEditor
ASCIIEditor(x=<yellow>0</yellow>, <olive>scale</olive>=.<yellow>1</yellow>)

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="ASCIIEditor">
        <h1>ASCIIEditor<a style="color: gray; font-weight:normal;" href="#GridEditor">(GridEditor)</a></h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/prefabs/grid_editor.py"><gray>ursina/prefabs/grid_editor</gray></a><br><br>
        <div class="params">ASCIIEditor(size=(61,28), palette=(' ', '#', '|', 'A', '/', '\\', 'o', '_', '-', 'i', 'M', '.'), font='VeraMono.ttf', canvas_color=color.black, line_height=1.1, **kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.text_entity<gray> = Text(parent=self.parent, text=text, x=-.0, y=.5, line_height=line_height, font=font)</gray></td><td></td>
            </tr>
            <tr>
                <td>.scale<gray> = (self.text_entity.width, self.text_entity.height)</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;render()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(ASCIIEditor_example)">copy</button><p id="ASCIIEditor_example">app = Ursina(borderless=False)
<green><green>''</green>'
pixel editor example, it's basically a drawing tool.
can be useful for level editors and such
here we create a new texture, but can also give it an existing texture to modify.
<green>''</green>'</green>
<purple>from</purple> PIL <purple>import</purple> Image
t = Texture(Image.new(<olive>mode</olive>=<green>'RGBA'</green>, size=(<yellow>3</yellow><yellow>2</yellow>,<yellow>3</yellow><yellow>2</yellow>), <olive>color</olive>=(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>,<yellow>1</yellow>)))
<purple>from</purple> ursina.prefabs.grid_editor <purple>import</purple> PixelEditor
editor = PixelEditor(<olive>parent</olive>=scene, <olive>texture</olive>=load_texture(<green>'brick'</green>), <olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>)

camera.orthographic = True
camera.fov = <yellow>1</yellow><yellow>5</yellow>
EditorCamera(rotation_speed=<yellow>0</yellow>)

<purple>from</purple> ursina.prefabs.grid_editor <purple>import</purple> ASCIIEditor
<purple><b>ASCIIEditor</b></purple>(x=<yellow>0</yellow>, <olive>scale</olive>=.<yellow>1</yellow>)

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="grid_layout">
        <h1>grid_layout</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/scripts/grid_layout.py"><gray>ursina/scripts/grid_layout</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;grid_layout(<gray>l, max_x=8, max_y=8, spacing=(0,0,0), origin=(-.5,.5,0), offset=(0,0,0)</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(grid_layout_example)">copy</button><p id="grid_layout_example">app = Ursina()

center = <olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>, <olive>scale</olive>=.<yellow>1</yellow>, <olive>color</olive>=color.red)
p = <olive>Entity</olive>()
<purple>for</purple> i in <blue>range</blue>(<yellow>4</yellow>*<yellow>5</yellow>):
    b = Button(<olive>parent</olive>=p, <olive>model</olive>=<green>'quad'</green>, <olive>scale</olive>=Vec2(.<yellow>2</yellow>,.<yellow>1</yellow>), <olive>text</olive>=str(i), <olive>color</olive>=color.tint(color.random_color(),-.<yellow>6</yellow>))
    b.text_entity.<olive>scale</olive>=<yellow>1</yellow>
t = time.time()
<purple><b>grid_layout</b></purple>(p.children, max_x=<yellow>7</yellow>, max_<olive>y</olive>=<yellow>1</yellow><yellow>0</yellow>, <olive>origin</olive>=(<yellow>0</yellow>, .<yellow>5</yellow>), spacing=(.<yellow>1</yellow><yellow>5</yellow>, <yellow>0</yellow>))
center = <olive>Entity</olive>(<olive>parent</olive>=camera.ui, <olive>model</olive>=Circle(), <olive>scale</olive>=.<yellow>0</yellow><yellow>0</yellow><yellow>5</yellow>, <olive>color</olive>=color.lime)
EditorCamera()
<blue>print</blue>(time.time() - t)</p>
</div>

</div>
<br>
    <div class="class_box" id="duplicate">
        <h1>duplicate</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/duplicate.py"><gray>ursina/duplicate</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;duplicate(<gray>entity, copy_children=True, *args, **kwargs): # use a for loop instead of duplicate(</gray>)</td> <td><span>use a for loop instead of duplicate() if you can.</span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(duplicate_example)">copy</button><p id="duplicate_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina <purple>import</purple> Ursina, Button, scene, EditorCamera
app = Ursina()


e = Button(<olive>parent</olive>=scene, <olive>scale</olive>=<yellow>1</yellow>, <olive>text</olive>=<green>'yolo'</green>)
e<yellow>2</yellow> = <purple><b>duplicate</b></purple>(e, x=<yellow>1</yellow>.<yellow>2</yellow><yellow>5</yellow>)
EditorCamera()
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="SmoothFollow">
        <h1>SmoothFollow</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/scripts/smooth_follow.py"><gray>ursina/scripts/smooth_follow</gray></a><br><br>
        <div class="params">SmoothFollow(target=None, offset=(0,0,0), speed=8, rotation_speed=0, rotation_offset=(0,0,0))</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.target<gray> = target</gray></td><td></td>
            </tr>
            <tr>
                <td>.offset<gray> = offset</gray></td><td></td>
            </tr>
            <tr>
                <td>.speed<gray> = speed</gray></td><td></td>
            </tr>
            <tr>
                <td>.rotation_speed<gray> = rotation_speed</gray></td><td></td>
            </tr>
            <tr>
                <td>.rotation_offset<gray> = rotation_offset</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(SmoothFollow_example)">copy</button><p id="SmoothFollow_example">app = Ursina()

player = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.orange)

<purple>def</purple> update():
    player.x += held_keys[<green>'d'</green>] * .<yellow>1</yellow>
    player.x -= held_keys[<green>'a'</green>] * .<yellow>1</yellow>

e = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>)
sf = e.add_script(<purple><b>SmoothFollow</b></purple>(target=player, offset=(<yellow>0</yellow>,<yellow>2</yellow>,<yellow>0</yellow>)))

<purple>def</purple> input(key):
    global sf
    <purple>if</purple> key == <green>'1'</green> and sf in e.scripts:
        e.scripts.remove(sf)

EditorCamera()
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="Scrollable">
        <h1>Scrollable</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/scripts/scrollable.py"><gray>ursina/scripts/scrollable</gray></a><br><br>
        <div class="params">Scrollable(**kwargs)</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.max<gray> = inf</gray></td><td></td>
            </tr>
            <tr>
                <td>.min<gray> = -inf</gray></td><td></td>
            </tr>
            <tr>
                <td>.scroll_speed<gray> = .05</gray></td><td></td>
            </tr>
            <tr>
                <td>.scroll_smoothing<gray> = 16</gray></td><td></td>
            </tr>
            <tr>
                <td>.axis<gray> = 'y'</gray></td><td></td>
            </tr>
            <tr>
                <td>.target_value<gray> = None</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(Scrollable_example)">copy</button><p id="Scrollable_example"><green><green>''</green>'
This will make target entity move up or down when you hover the entity/its children
while scrolling the scroll wheel.
<green>''</green>'</green>

app = Ursina()
p = Button(<olive>model</olive>=<green>'quad'</green>, <olive>scale</olive>=(.<yellow>4</yellow>, .<yellow>8</yellow>), <olive>collider</olive>=<green>'box'</green>)
<purple>for</purple> i in <blue>range</blue>(<yellow>8</yellow>):
    Button(<olive>parent</olive>=p , scale_<olive>y</olive>=.<yellow>0</yellow><yellow>5</yellow>, <olive>text</olive>=f<green>'giopwjoigjwr{i}'</green>, origin_<olive>y</olive>=.<yellow>5</yellow>, <olive>y</olive>=.<yellow>5</yellow>-(i*.<yellow>0</yellow><yellow>5</yellow>))

p.add_script(<purple><b>Scrollable</b></purple>())
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="NoclipMode">
        <h1>NoclipMode</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/scripts/noclip_mode.py"><gray>ursina/scripts/noclip_mode</gray></a><br><br>
        <div class="params">NoclipMode(speed=10, require_key='shift')</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.speed<gray> = speed</gray></td><td></td>
            </tr>
            <tr>
                <td>.require_key<gray> = require_key</gray></td><td></td>
            </tr>
            <tr>
                <td>.ignore_paused<gray> = True</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(NoclipMode_example)">copy</button><p id="NoclipMode_example">app = Ursina()

player = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.orange)
<olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>)
EditorCamera()


player.add_script(NoclipMode<yellow>2</yellow>d())
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="NoclipMode2d">
        <h1>NoclipMode2d</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/scripts/noclip_mode.py"><gray>ursina/scripts/noclip_mode</gray></a><br><br>
        <div class="params">NoclipMode2d(speed=10, require_key='shift')</div><br>
        <table> <!-- attributes -->
            <tr>
                <td>.speed<gray> = speed</gray></td><td></td>
            </tr>
            <tr>
                <td>.require_key<gray> = require_key</gray></td><td></td>
            </tr>
            <tr>
                <td>.ignore_paused<gray> = True</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;input(<gray>key</gray>)</td> <td><span></span></td>
            </tr>
            <tr>
                <td> &nbsp;update()</td> <td><span></span></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(NoclipMode2d_example)">copy</button><p id="NoclipMode2d_example">app = Ursina()

player = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.orange)
<olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>)
EditorCamera()


player.add_script(NoclipMode<yellow>2</yellow>d())
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="build">
        <h1>build</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/build.py"><gray>ursina/build</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>.project_folder<gray> = Path.cwd()</gray></td><td></td>
            </tr>
            <tr>
                <td>.project_name<gray> = project_folder.stem</gray></td><td></td>
            </tr>
            <tr>
                <td>.build_folder<gray> = Path(project_folder / f'build_{platform.system()}')</gray></td><td></td>
            </tr>
            <tr>
                <td>.build_folder.mkdir(exist_ok=True)</td><td></td>
            </tr>
            <tr>
                <td>.ignore_folders<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.ignore_filetypes<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.compressed_textures<gray> = []</gray></td><td></td>
            </tr>
            <tr>
                <td>.compressed_textures_folder<gray> = Path(project_folder/'textures_compressed')</gray></td><td></td>
            </tr>
            <tr>
                <td>.python_dest<gray> = Path(build_folder / 'python')</gray></td><td></td>
            </tr>
            <tr>
                <td>.python_dlls_dest<gray> = Path(build_folder / 'python/DLLs')</gray></td><td></td>
            </tr>
            <tr>
                <td>.python_lib_dest<gray> = Path(build_folder / 'python/Lib')</gray></td><td></td>
            </tr>
            <tr>
                <td>.src_dest<gray> = Path(build_folder / 'src')</gray></td><td></td>
            </tr>
            <tr>
                <td>.build_engine<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.build_game<gray> = True</gray></td><td></td>
            </tr>
            <tr>
                <td>.entry_point<gray> = 'main.py'</gray></td><td></td>
            </tr>
            <tr>
                <td>.start_time<gray> = time.time()</gray></td><td></td>
            </tr>
        </table><br>
        <div><gray>functions:</gray></div>
        <table>
            <tr>
                <td> &nbsp;copytree(<gray>src, dst, symlinks=False, ignore_patterns=[], ignore_filetypes=[]</gray>)</td> <td><span></span></td>
            </tr>
        </table><br>

</div>
<br>
    <div class="class_box" id="models">
        <h1>models</h1>
        <table> <!-- attributes -->
            <tr>
                <td>quad</td><td></td>
            </tr>
            <tr>
                <td>wireframe_cube</td><td></td>
            </tr>
            <tr>
                <td>plane</td><td></td>
            </tr>
            <tr>
                <td>circle</td><td></td>
            </tr>
            <tr>
                <td>diamond</td><td></td>
            </tr>
            <tr>
                <td>wireframe_quad</td><td></td>
            </tr>
            <tr>
                <td>sphere</td><td></td>
            </tr>
            <tr>
                <td>cube</td><td></td>
            </tr>
            <tr>
                <td>icosphere</td><td></td>
            </tr>
            <tr>
                <td>cube_uv_top</td><td></td>
            </tr>
            <tr>
                <td>arrow</td><td></td>
            </tr>
            <tr>
                <td>sky_dome</td><td></td>
            </tr>
        </table><br>

</div>
<br>
    <div class="class_box" id="textures">
        <h1>textures</h1>
        <table> <!-- attributes -->
            <tr>
                <td>noise</td><td></td>
            </tr>
            <tr>
                <td>grass</td><td></td>
            </tr>
            <tr>
                <td>vignette</td><td></td>
            </tr>
            <tr>
                <td>arrow_right</td><td></td>
            </tr>
            <tr>
                <td>test_tileset</td><td></td>
            </tr>
            <tr>
                <td>tilemap_test_level</td><td></td>
            </tr>
            <tr>
                <td>shore</td><td></td>
            </tr>
            <tr>
                <td>file_icon</td><td></td>
            </tr>
            <tr>
                <td>sky_sunset</td><td></td>
            </tr>
            <tr>
                <td>radial_gradient</td><td></td>
            </tr>
            <tr>
                <td>circle</td><td></td>
            </tr>
            <tr>
                <td>perlin_noise</td><td></td>
            </tr>
            <tr>
                <td>brick</td><td></td>
            </tr>
            <tr>
                <td>grass_tintable</td><td></td>
            </tr>
            <tr>
                <td>circle_outlined</td><td></td>
            </tr>
            <tr>
                <td>ursina_logo</td><td></td>
            </tr>
            <tr>
                <td>arrow_down</td><td></td>
            </tr>
            <tr>
                <td>cog</td><td></td>
            </tr>
            <tr>
                <td>vertical_gradient</td><td></td>
            </tr>
            <tr>
                <td>white_cube</td><td></td>
            </tr>
            <tr>
                <td>horizontal_gradient</td><td></td>
            </tr>
            <tr>
                <td>folder</td><td></td>
            </tr>
            <tr>
                <td>rainbow</td><td></td>
            </tr>
            <tr>
                <td>heightmap_1</td><td></td>
            </tr>
            <tr>
                <td>sky_default</td><td></td>
            </tr>
        </table><br>

</div>
<br>
    <div class="class_box" id="unlit_shader">
        <h1>unlit_shader</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/unlit_shader.py"><gray>ursina/shaders/unlit_shader</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>default_input</td><td></td>
            </tr>
            <tr>
                <td>    'texture_scale' : Vec2(1,1),</td><td></td>
            </tr>
            <tr>
                <td>    'texture_offset' : Vec2(0.0, 0.0),</td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(unlit_shader_example)">copy</button><p id="unlit_shader_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina.prefabs.primitives <purple>import</purple> *
app = Ursina()

shader = unlit_shader

ground = GrayPlane(<olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>, <olive>y</olive>=-<yellow>2</yellow>, <olive>texture</olive>=<green>'shore'</green>, <olive>shader</olive>=shader, <olive>texture_scale</olive>=(<yellow>1</yellow><yellow>0</yellow>,<yellow>1</yellow><yellow>0</yellow>))
ground.set_shader_input(<green>'texture_scale'</green>, Vec2(<yellow>2</yellow>, <yellow>1</yellow>))
EditorCamera()

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="lit_with_shadows_shader">
        <h1>lit_with_shadows_shader</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/lit_with_shadows_shader.py"><gray>ursina/shaders/lit_with_shadows_shader</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>default_input</td><td></td>
            </tr>
            <tr>
                <td>    'texture_scale': Vec2(1,1),</td><td></td>
            </tr>
            <tr>
                <td>    'texture_offset': Vec2(0,0),</td><td></td>
            </tr>
            <tr>
                <td>    'shadow_color' : Color(0, .5, 1, .25),</td><td></td>
            </tr>
            <tr>
                <td>    'shadow_blur': .005,</td><td></td>
            </tr>
            <tr>
                <td>    'shadow_samples': 4</td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(lit_with_shadows_shader_example)">copy</button><p id="lit_with_shadows_shader_example"><purple>from</purple> ursina <purple>import</purple> *

app = Ursina()
shader = lit_with_shadows_shader

a = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>shader</olive>=shader, <olive>y</olive>=<yellow>1</yellow>, <olive>color</olive>=color.light_gray)
<olive>Entity</olive>(<olive>model</olive>=<green>'sphere'</green>, <olive>texture</olive>=<green>'shore'</green>, <olive>y</olive>=<yellow>2</yellow>, x=<yellow>1</yellow>, <olive>shader</olive>=shader)

<olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>scale</olive>=<yellow>1</yellow><yellow>6</yellow>, <olive>texture</olive>=<green>'grass'</green>, <olive>shader</olive>=lit_with_shadows_shader)
<purple>from</purple> ursina.lights <purple>import</purple> DirectionalLight
sun = DirectionalLight(shadow_map_resolution=(<yellow>2</yellow><yellow>0</yellow><yellow>4</yellow><yellow>8</yellow>,<yellow>2</yellow><yellow>0</yellow><yellow>4</yellow><yellow>8</yellow>))
sun.look_at(Vec3(-<yellow>1</yellow>,-<yellow>1</yellow>,-<yellow>1</yellow><yellow>0</yellow>))
scene.fog_density = (<yellow>1</yellow>, <yellow>5</yellow><yellow>0</yellow>)
Sky(<olive>color</olive>=color.light_gray)
EditorCamera()

<purple>def</purple> update():
    a.x += (held_keys[<green>'d'</green>] - held_keys[<green>'a'</green>]) * time.dt * <yellow>5</yellow>
    a.y += (held_keys[<green>'e'</green>] - held_keys[<green>'q'</green>]) * time.dt * <yellow>5</yellow>
    a.z += (held_keys[<green>'w'</green>] - held_keys[<green>'s'</green>]) * time.dt * <yellow>5</yellow>

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'r'</green>:
        <purple>if</purple> sun.color == color.white:
            sun.color = color.red
        <purple>else</purple>:
            sun.color = color.white

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="matcap_shader">
        <h1>matcap_shader</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/matcap_shader.py"><gray>ursina/shaders/matcap_shader</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(matcap_shader_example)">copy</button><p id="matcap_shader_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina.prefabs.primitives <purple>import</purple> *
app = Ursina()
window.<olive>color</olive>=color.black

shader = matcap_shader

a = WhiteCube(<olive>shader</olive>=shader, <olive>texture</olive>=<green>'shore'</green>)
b = WhiteSphere(<olive>shader</olive>=shader, rotation_<olive>y</olive>=<yellow>1</yellow><yellow>8</yellow><yellow>0</yellow>, x=<yellow>3</yellow>, <olive>texture</olive>=<green>'shore'</green>)
GrayPlane(<olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>, <olive>y</olive>=-<yellow>2</yellow>, <olive>texture</olive>=<green>'shore'</green>)

Sky(<olive>color</olive>=color.light_gray)
EditorCamera()

<purple>def</purple> update():
    b.rotation_z += <yellow>1</yellow>
    b.rotation_y += <yellow>1</yellow>
    b.rotation_x += <yellow>1</yellow>
<blue>print</blue>(<green>'-----------------'</green>, repr(a.shader))
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="colored_lights_shader">
        <h1>colored_lights_shader</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/colored_lights_shader.py"><gray>ursina/shaders/colored_lights_shader</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>default_input</td><td></td>
            </tr>
            <tr>
                <td>    'top_color': color.hsv(220, .12, .82),</td><td></td>
            </tr>
            <tr>
                <td>    'bottom_color': color.hsv(285, .13, .47),</td><td></td>
            </tr>
            <tr>
                <td>    'left_color': color.hsv(217, .3, .68),</td><td></td>
            </tr>
            <tr>
                <td>    'right_color': color.hsv(0, .25, .93),</td><td></td>
            </tr>
            <tr>
                <td>    'front_color': color.hsv(231, .08, .69),</td><td></td>
            </tr>
            <tr>
                <td>    'back_color': color.hsv(240, .05, .76),</td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(colored_lights_shader_example)">copy</button><p id="colored_lights_shader_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina.prefabs.primitives <purple>import</purple> *
app = Ursina()
window.<olive>color</olive>=color.black

shader = colored_lights_shader

<olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>color</olive>=color.white, <olive>shader</olive>=colored_lights_shader)
e = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, x=<yellow>1</yellow>.<yellow>2</yellow>, <olive>shader</olive>=colored_lights_shader, <olive>color</olive>=color.white)
e.set_shader_input(<green>'top_color'</green>, hsv(<yellow>0</yellow>,<yellow>1</yellow>,<yellow>1</yellow>))
e.set_shader_input(<green>'bottom_color'</green>, hsv(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>))
e.set_shader_input(<green>'left_color'</green>, hsv(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>))
e.set_shader_input(<green>'right_color'</green>, hsv(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>))
e.set_shader_input(<green>'front_color'</green>, hsv(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>))
e.set_shader_input(<green>'back_color'</green>, hsv(<yellow>0</yellow>,<yellow>0</yellow>,<yellow>0</yellow>))

GrayPlane(<olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>, <olive>y</olive>=-<yellow>2</yellow>, <olive>texture</olive>=<green>'shore'</green>)

Sky(<olive>color</olive>=color.light_gray)
EditorCamera(rotate_around_mouse_hit=False)


EditorCamera()

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="fresnel_shader">
        <h1>fresnel_shader</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/fresnel_shader.py"><gray>ursina/shaders/fresnel_shader</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>default_input</td><td></td>
            </tr>
            <tr>
                <td>    'texture_scale' : Vec2(1,1),</td><td></td>
            </tr>
            <tr>
                <td>    'texture_offset' : Vec2(0.0, 0.0),</td><td></td>
            </tr>
            <tr>
                <td>    'fresnel_color' : color.light_gray,</td><td></td>
            </tr>
            <tr>
                <td>    'fresnel_texture' : Func(load_texture, 'white_cube'),</td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(fresnel_shader_example)">copy</button><p id="fresnel_shader_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()

b = <olive>Entity</olive>(<olive>model</olive>=<green>'sphere'</green>, <olive>color</olive>=color.black, <olive>shader</olive>=fresnel_shader)
ground = <olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>color</olive>=color.gray, <olive>shader</olive>=fresnel_shader, <olive>y</olive>=-<yellow>1</yellow>, <olive>scale</olive>=<yellow>6</yellow><yellow>4</yellow>, <olive>texture</olive>=<green>'grass'</green>, <olive>texture_scale</olive>=Vec2(<yellow>3</yellow><yellow>2</yellow>,<yellow>3</yellow><yellow>2</yellow>))
ground.set_shader_input(<green>'fresnel_color'</green>, color.gray)
ground.set_shader_input(<green>'fresnel_texture'</green>, load_texture(<green>'white_cube'</green>))
EditorCamera()

<purple>for</purple> i in <blue>range</blue>(<yellow>1</yellow><yellow>6</yellow>):
    e = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, origin_<olive>y</olive>=-.<yellow>5</yellow>, <olive>scale</olive>=<yellow>2</yellow>, <olive>texture</olive>=<green>'brick'</green>, <olive>texture_scale</olive>=(<yellow>1</yellow>,<yellow>2</yellow>),
        x=random.uniform(-<yellow>8</yellow>,<yellow>8</yellow>),
        <olive>z</olive>=random.uniform(-<yellow>8</yellow>,<yellow>8</yellow>) + <yellow>8</yellow>,
        scale_y = random.uniform(<yellow>2</yellow>,<yellow>3</yellow>),
        <olive>color</olive>=color.hsv(<yellow>0</yellow>, <yellow>0</yellow>, random.uniform(.<yellow>9</yellow>, <yellow>1</yellow>)),
        <olive>shader</olive>=fresnel_shader,
        )
    e.set_shader_input(<green>'fresnel_texture'</green>, load_texture(<green>'brick'</green>))

<purple>def</purple> update():
    <purple>for</purple> e in scene.entities:
        <purple>if</purple> <blue>hasattr</blue>(e, <green>'shader'</green>) and e.shader == fresnel_shader:
            e.set_shader_input(<green>'camera_world_position'</green>, camera.world_position)





app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="projector_shader">
        <h1>projector_shader</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/projector_shader.py"><gray>ursina/shaders/projector_shader</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(projector_shader_example)">copy</button><p id="projector_shader_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()

<olive>Entity</olive>.default_shader = projector_shader

editor_camera = EditorCamera(<olive>rotation_x</olive>=<yellow>3</yellow><yellow>0</yellow>,)
light = <olive>Entity</olive>(<olive>model</olive>=<green>'sphere'</green>, unlit=True)
ground = <olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>collider</olive>=<green>'box'</green>, <olive>scale</olive>=<yellow>6</yellow><yellow>4</yellow>, <olive>texture</olive>=<green>'grass'</green>, <olive>texture_scale</olive>=(<yellow>4</yellow>,<yellow>4</yellow>))

random.seed(<yellow>0</yellow>)
<purple>for</purple> i in <blue>range</blue>(<yellow>1</yellow><yellow>6</yellow>):
    <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, origin_<olive>y</olive>=-.<yellow>5</yellow>, <olive>scale</olive>=<yellow>2</yellow>, <olive>texture</olive>=<green>'brick'</green>, <olive>texture_scale</olive>=(<yellow>1</yellow>,<yellow>2</yellow>),
        x=random.uniform(-<yellow>8</yellow>,<yellow>8</yellow>),
        <olive>z</olive>=random.uniform(-<yellow>8</yellow>,<yellow>8</yellow>) + <yellow>8</yellow>,
        <olive>collider</olive>=<green>'box'</green>,
        scale_y = random.uniform(<yellow>2</yellow>,<yellow>3</yellow>),
        <olive>color</olive>=color.hsv(<yellow>0</yellow>, <yellow>0</yellow>, random.uniform(.<yellow>9</yellow>, <yellow>1</yellow>))
    )

scene.fog_density = (<yellow>1</yellow><yellow>0</yellow>, <yellow>2</yellow><yellow>0</yellow><yellow>0</yellow>)

projector_texture = load_texture(<green>'vignette'</green>, application.internal_textures_folder)
projector_shader.default_input[<green>'projector_texture'</green>] = projector_texture

<purple>def</purple> update():
    light.x += (held_keys[<green>'d'</green>] - held_keys[<green>'a'</green>]) * time.dt * <yellow>3</yellow>
    light.z += (held_keys[<green>'w'</green>] - held_keys[<green>'s'</green>]) * time.dt * <yellow>3</yellow>

    <purple>for</purple> e in scene.entities:
        <purple>if</purple> <blue>hasattr</blue>(e,<green>'shader'</green>) and e.shader == projector_shader:
            e.set_shader_input(<green>'projector_uv_offset'</green>, light.world_position.xz * projector_shader.default_input[<green>'projector_uv_scale'</green>])

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="texture_blend_shader">
        <h1>texture_blend_shader</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/texture_blend_shader.py"><gray>ursina/shaders/texture_blend_shader</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(texture_blend_shader_example)">copy</button><p id="texture_blend_shader_example"><purple>from</purple> ursina <purple>import</purple> *
Texture.default_filtering = <green>'bilinear'</green>
app = Ursina(vsync=False)

e = <olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>shader</olive>=texture_blend_shader, <olive>texture</olive>=<green>'shore'</green>)
e.set_shader_input(<green>'red_texture'</green>, load_texture(<green>'dirt'</green>))
e.set_shader_input(<green>'green_texture'</green>, load_texture(<green>'grass_tintable.tif'</green>))
e.set_shader_input(<green>'green_tint'</green>, color.hex(<green>'#6f6d24'</green>))
e.set_shader_input(<green>'blue_texture'</green>, load_texture(<green>'cobblestone.tif'</green>))
blend_map = load_texture(<green>'texture_blend_map_example'</green>)
e.set_shader_input(<green>'blend_map'</green>, blend_map)
e.scale_x = blend_map.width / blend_map.height
e.scale *= <yellow>2</yellow><yellow>0</yellow><yellow>0</yellow>


EditorCamera(<olive>rotation_x</olive>=<yellow>3</yellow><yellow>0</yellow>)

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'space'</green>:
        <purple>if</purple> e.shader:
            e.shader = None
        <purple>else</purple>:
            e.shader = texture_blend_shader

    <purple>if</purple> key == <green>'left mouse up'</green>:
        blend_map.apply()


e.collider = <green>'mesh'</green>
<purple>def</purple> update():
    <purple>if</purple> mouse.left and mouse.hovered_entity == e:
        x, _, y = mouse.point + Vec3(.<yellow>5</yellow>)
        <blue>print</blue>(x, y)
        blend_map.set_pixel(int(x*blend_map.width), int(y*blend_map.height), color.green)
        blend_map.apply()


app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="instancing_shader">
        <h1>instancing_shader</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/instancing_shader.py"><gray>ursina/shaders/instancing_shader</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(instancing_shader_example)">copy</button><p id="instancing_shader_example"><purple>from</purple> ursina <purple>import</purple> Ursina, window, <olive>Entity</olive>, EditorCamera, Vec<yellow>3</yellow>, color, application, time, Cone
<purple>import</purple> random
window.vsync = False
app = Ursina()

instances = []
<olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>texture</olive>=<green>'grass'</green>, <olive>scale</olive>=<yellow>1</yellow><yellow>2</yellow><yellow>8</yellow>)
application.asset_folder = application.asset_folder.parent.parent
p = <olive>Entity</olive>(<olive>model</olive>=Cone(<yellow>5</yellow>), <olive>y</olive>=<yellow>1</yellow>, <olive>texture</olive>=<green>'brick'</green>)
p.model.uvs = [(v[<yellow>0</yellow>],v[<yellow>1</yellow>]) <purple>for</purple> v in p.model.vertices]
p.model.generate()
p.shader = instancing_shader
p.setInstanceCount(<yellow>2</yellow><yellow>5</yellow><yellow>6</yellow>)

<purple>for</purple> z in <blue>range</blue>(<yellow>1</yellow><yellow>6</yellow>):
    <purple>for</purple> x in <blue>range</blue>(<yellow>1</yellow><yellow>6</yellow>):
        e = <olive>Entity</olive>(add_to_scene_entities=False, <olive>position</olive>=Vec3(x, <yellow>0</yellow>, z), <olive>color</olive>=color.lime, rotation_<olive>y</olive>=random.random()*<yellow>3</yellow><yellow>6</yellow><yellow>0</yellow>)
        instances.append(e)
        <blue>print</blue>(e.quaternion, Quat())

p.set_shader_input(<green>'position_offsets'</green>, [e.position*<yellow>4</yellow> <purple>for</purple> e in instances])
p.set_shader_input(<green>'rotation_offsets'</green>, [e.quaternion <purple>for</purple> e in instances])
p.set_shader_input(<green>'scale_multipliers'</green>,[e.scale*random.uniform(.<yellow>9</yellow>,<yellow>2</yellow>) <purple>for</purple> e in instances])
p.set_shader_input(<green>'colors'</green>, p.model.colors)

<blue>print</blue>(len(p.model.vertices) * len(instances))
EditorCamera()

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="triplanar_shader">
        <h1>triplanar_shader</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/triplanar_shader.py"><gray>ursina/shaders/triplanar_shader</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>default_input</td><td></td>
            </tr>
            <tr>
                <td>    'texture_scale' : Vec2(1,1),</td><td></td>
            </tr>
            <tr>
                <td>    'side_texture' : 'brick',</td><td></td>
            </tr>
            <tr>
                <td>    'side_texture_scale' : Vec2(1,1),</td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(triplanar_shader_example)">copy</button><p id="triplanar_shader_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina.prefabs.primitives <purple>import</purple> *
app = Ursina()
window.<olive>color</olive>=color.black

shader = triplanar_shader

a = Draggable(<olive>parent</olive>=scene, <olive>model</olive>=<green>'cube'</green>, <olive>shader</olive>=shader, <olive>texture</olive>=load_texture(<green>'brick'</green>), plane_direction=Vec3(<yellow>0</yellow>,<yellow>1</yellow>,<yellow>0</yellow>))
t = load_texture(<green>'brick'</green>)._texture
<blue>print</blue>(<green>'------'</green>, type(t))
a.set_shader_input(<green>'side_texture'</green>, load_texture(<green>'brick'</green>))

b = AzureSphere(<olive>shader</olive>=shader, rotation_<olive>y</olive>=<yellow>1</yellow><yellow>8</yellow><yellow>0</yellow>, x=<yellow>3</yellow>, <olive>texture</olive>=<green>'grass'</green>)
b.texture.filtering = False
GrayPlane(<olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>, <olive>y</olive>=-<yellow>2</yellow>, <olive>texture</olive>=<green>'shore'</green>)
b.set_shader_input(<green>'side_texture'</green>, load_texture(<green>'brick'</green>))

Sky(<olive>color</olive>=color.light_gray)
EditorCamera()

<purple>def</purple> set_side_texture_scale():
    value = side_texture_scale_slider.value
    b.set_shader_input(<green>'side_texture_scale'</green>, Vec2(value, value))
    a.set_shader_input(<green>'side_texture_scale'</green>, Vec2(value, value))

side_texture_scale_slider = Slider(<olive>text</olive>=<green>'side_texture_scale'</green>, min=<yellow>0</yellow>, max=<yellow>1</yellow><yellow>0</yellow>, default=<yellow>1</yellow>, dynamic=True, on_value_changed=set_side_texture_scale)


<purple>def</purple> update():
    b.rotation_y += <yellow>1</yellow>
    b.rotation_x += <yellow>1</yellow>

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="normals_shader">
        <h1>normals_shader</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/normals_shader.py"><gray>ursina/shaders/normals_shader</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(normals_shader_example)">copy</button><p id="normals_shader_example"><purple>from</purple> ursina <purple>import</purple> *
<purple>from</purple> ursina.prefabs.primitives <purple>import</purple> *
app = Ursina()
window.<olive>color</olive>=color.black

shader = normals_shader

a = WhiteCube(<olive>shader</olive>=shader)
b = AzureSphere(rotation_<olive>y</olive>=<yellow>1</yellow><yellow>8</yellow><yellow>0</yellow>, x=<yellow>3</yellow>)
b.shader = shader
GrayPlane(<olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>, <olive>y</olive>=-<yellow>2</yellow>, <olive>texture</olive>=<green>'shore'</green>)

Sky(<olive>color</olive>=color.light_gray)
EditorCamera()

<purple>def</purple> update():
    b.rotation_z += <yellow>1</yellow>
    b.rotation_y += <yellow>1</yellow>
    b.rotation_x += <yellow>1</yellow>

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="transition_shader">
        <h1>transition_shader</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/transition_shader.py"><gray>ursina/shaders/transition_shader</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(transition_shader_example)">copy</button><p id="transition_shader_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()
window.color = color._<yellow>1</yellow><yellow>6</yellow>
Texture.default_filtering = <green>'bilinear'</green>

e = <olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>, <olive>shader</olive>=transition_shader, <olive>scale</olive>=<yellow>5</yellow>, cutoff=<yellow>0</yellow>, 
    <olive>texture</olive>=<green>'sword_slash'</green>, <olive>color</olive>=color.azure
    )
mask = load_texture(<green>'sword_slash'</green>)
e.set_shader_input(<green>'mask_texture'</green>, mask)
EditorCamera()

min_cutoff_slider = Slider(<yellow>0</yellow>, <yellow>1</yellow>, dynamic=True, <olive>y</olive>=-.<yellow>4</yellow>)
<purple>def</purple> on_value_changed():
    e.set_shader_input(<green>'min_cutoff'</green>, min_cutoff_slider.value)
min_cutoff_slider.on_value_changed = on_value_changed

max_cutoff_slider = Slider(<yellow>0</yellow>, <yellow>1</yellow>, default=<yellow>1</yellow>, dynamic=True, <olive>y</olive>=-.<yellow>4</yellow><yellow>5</yellow>)
<purple>def</purple> on_value_changed():
    e.set_shader_input(<green>'max_cutoff'</green>, max_cutoff_slider.value)
max_cutoff_slider.on_value_changed = on_value_changed


<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'space'</green>:
        e.cutoff = <yellow>0</yellow>
        e.animate(<green>'cutoff'</green>, <yellow>1</yellow>, duration=.<yellow>1</yellow>, <olive>curve</olive>=curve.linear, dela<olive>y</olive>=.<yellow>0</yellow><yellow>5</yellow>)


app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="fxaa">
        <h1>fxaa</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/screenspace_shaders/fxaa.py"><gray>ursina/shaders/screenspace_shaders/fxaa</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>default_input</td><td></td>
            </tr>
            <tr>
                <td>    'window_size': Vec2(1280,720),</td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(fxaa_example)">copy</button><p id="fxaa_example">app = Ursina()
window.<olive>color</olive>=color.black

<olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow>, <olive>y</olive>=-<yellow>2</yellow>, <olive>texture</olive>=<green>'shore'</green>)
EditorCamera()
<olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>, <olive>color</olive>=color.red, double_sided=True)
<olive>Entity</olive>(<olive>model</olive>=<green>'quad'</green>, <olive>color</olive>=color.green, <olive>z</olive>=-.<yellow>0</yellow><yellow>0</yellow><yellow>1</yellow>, <olive>scale</olive>=.<yellow>5</yellow>, <olive>texture</olive>=<green>'circle'</green>)
camera.shader = fxaa_shader
camera.clip_plane_far=<yellow>1</yellow><yellow>0</yellow><yellow>0</yellow>
Sky()

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'space'</green>:
        <purple>if</purple> <purple>not</purple> camera.shader:
            camera.shader = fxaa_shader
        <purple>else</purple>:
            camera.shader = None


app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="ssao">
        <h1>ssao</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/screenspace_shaders/ssao.py"><gray>ursina/shaders/screenspace_shaders/ssao</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(ssao_example)">copy</button><p id="ssao_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()

e = <olive>Entity</olive>(<olive>model</olive>=<green>'sphere'</green>, <olive>color</olive>=color.orange)
e = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=-<yellow>1</yellow>)
e = <olive>Entity</olive>(<olive>model</olive>=<green>'plane'</green>, <olive>scale</olive>=<yellow>1</yellow><yellow>0</yellow><yellow>0</yellow>, <olive>y</olive>=-<yellow>1</yellow>)
camera.shader = ssao_shader

EditorCamera()

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'space'</green>:
        <purple>if</purple> camera.shader:
            camera.shader = None
        <purple>else</purple>:
            camera.shader = ssao_shader


random.seed(<yellow>2</yellow>)
<purple>for</purple> i in <blue>range</blue>(<yellow>2</yellow><yellow>0</yellow>):
    e = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>position</olive>=Vec3(random.random(),random.random(),random.random())*<yellow>3</yellow>, <olive>rotation</olive>=Vec3(random.random(),random.random(),random.random())*<yellow>3</yellow><yellow>6</yellow><yellow>0</yellow>)
app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="camera_outline_shader">
        <h1>camera_outline_shader</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/screenspace_shaders/camera_outline_shader.py"><gray>ursina/shaders/screenspace_shaders/camera_outline_shader</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(camera_outline_shader_example)">copy</button><p id="camera_outline_shader_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()
<olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>texture</olive>=<green>'white_cube'</green>, <olive>color</olive>=color.red)
<olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>texture</olive>=<green>'white_cube'</green>, <olive>color</olive>=color.white, x=<yellow>1</yellow>.<yellow>1</yellow>)
<olive>Entity</olive>(<olive>model</olive>=<green>'sphere'</green>, <olive>texture</olive>=<green>'white_cube'</green>, <olive>color</olive>=color.gray, <olive>y</olive>=<yellow>1</yellow>.<yellow>1</yellow>)
camera.shader = empty_shader
<blue>print</blue>(camera.shader)

t = <yellow>0</yellow>
frame = <yellow>0</yellow>


<purple>def</purple> update():
  global t, frame
  t += time.dt

  frame += <yellow>1</yellow>


EditorCamera()

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="pixelation_shader">
        <h1>pixelation_shader</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/screenspace_shaders/pixelation_shader.py"><gray>ursina/shaders/screenspace_shaders/pixelation_shader</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(pixelation_shader_example)">copy</button><p id="pixelation_shader_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()

e = <olive>Entity</olive>(<olive>model</olive>=<green>'sphere'</green>, <olive>color</olive>=color.orange)
e = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=-<yellow>1</yellow>)
camera.shader = pixelation_shader
EditorCamera()

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="camera_contrast">
        <h1>camera_contrast</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/screenspace_shaders/camera_contrast.py"><gray>ursina/shaders/screenspace_shaders/camera_contrast</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>default_input</td><td></td>
            </tr>
            <tr>
                <td>    'contrast': 1,</td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(camera_contrast_example)">copy</button><p id="camera_contrast_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()

e = <olive>Entity</olive>(<olive>model</olive>=<green>'sphere'</green>)
e = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=-<yellow>1</yellow>)
camera.shader = camera_contrast_shader
camera.set_shader_input(<green>'contrast'</green>, <yellow>1</yellow>)

slider = ThinSlider(max=<yellow>2</yellow>, dynamic=True, <olive>position</olive>=(-.<yellow>2</yellow><yellow>5</yellow>, -.<yellow>4</yellow><yellow>5</yellow>))
<purple>def</purple> adjust_contrast():
    camera.set_shader_input("contrast", slider.value)
slider.on_value_changed = adjust_contrast

EditorCamera()

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="camera_vertical_blur">
        <h1>camera_vertical_blur</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/screenspace_shaders/camera_vertical_blur.py"><gray>ursina/shaders/screenspace_shaders/camera_vertical_blur</gray></a><br><br>
        <table> <!-- attributes -->
            <tr>
                <td>default_input</td><td></td>
            </tr>
            <tr>
                <td>=dict(</td><td></td>
            </tr>
            <tr>
                <td>    blur_size<gray> = .1</gray></td><td></td>
            </tr>
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(camera_vertical_blur_example)">copy</button><p id="camera_vertical_blur_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()
window.color = color._<yellow>1</yellow><yellow>6</yellow>

e = <olive>Entity</olive>(<olive>model</olive>=<green>'sphere'</green>, <olive>color</olive>=color.orange)
e = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=-<yellow>1</yellow>)
camera.shader = camera_vertical_blur_shader


slider = ThinSlider(max=.<yellow>1</yellow>, dynamic=True, <olive>position</olive>=(-.<yellow>2</yellow><yellow>5</yellow>, -.<yellow>4</yellow><yellow>5</yellow>))

<purple>def</purple> set_blur():
    <blue>print</blue>(slider.value)
    camera.set_shader_input("blur_size", slider.value)



slider.on_value_changed = set_blur
EditorCamera()

app.run()</p>
</div>

</div>
<br>
    <div class="class_box" id="camera_grayscale">
        <h1>camera_grayscale</h1>
        <a href="https://github.com/pokepetter/ursina/blob/master/ursina/shaders/screenspace_shaders/camera_grayscale.py"><gray>ursina/shaders/screenspace_shaders/camera_grayscale</gray></a><br><br>
        <table> <!-- attributes -->
        </table><br>
    <div><gray>example:</gray></div>
   <div class="example"><button class="copy_code_button" onclick="copy_to_clipboard(camera_grayscale_example)">copy</button><p id="camera_grayscale_example"><purple>from</purple> ursina <purple>import</purple> *
app = Ursina()

e = <olive>Entity</olive>(<olive>model</olive>=<green>'sphere'</green>, <olive>color</olive>=color.orange)
e = <olive>Entity</olive>(<olive>model</olive>=<green>'cube'</green>, <olive>y</olive>=-<yellow>1</yellow>)
camera.shader = camera_grayscale_shader
EditorCamera()

<purple>def</purple> input(key):
    <purple>if</purple> key == <green>'space'</green>:
        <purple>if</purple> camera.shader:
            camera.shader = None
        <purple>else</purple>:
            camera.shader = camera_grayscale_shader


app.run()</p>
</div>

</div>
<br>

</main_section>
</body>
</html>
